[svn r318] Fixed looping bug in the mythtv gnomevfs module. The file transfer requests were just 4kbytes, and the looping was a deadlock
1.1 --- a/libgnomevfs2-mythtv/modules/mythtv-method.c Tue Jan 30 22:27:59 2007 +0000
1.2 +++ b/libgnomevfs2-mythtv/modules/mythtv-method.c Wed Jan 31 21:44:45 2007 +0000
1.3 @@ -189,10 +189,12 @@
1.4
1.5 /* Loop sending the Myth File Transfer request:
1.6 * Retry whilst authentication fails and we supply it. */
1.7 - if ((myth_handle->buffer_remain = myth_handle->buffer->len) < MYTHTV_BUFFER_SIZE) {
1.8 - //if ( bytes_to_read > myth_handle->buffer_remain ) {
1.9 + //if (myth_handle->buffer_remain < MYTHTV_BUFFER_SIZE) {
1.10 + if ( bytes_to_read > myth_handle->buffer_remain ) {
1.11 GByteArray *tmp_buffer = g_byte_array_new();
1.12
1.13 + printf ("XXXXXXXXXXXXXX Pedindo %d %d\n", MYTHTV_BUFFER_SIZE, myth_handle->buffer_remain);
1.14 +
1.15 gint len = gmyth_file_transfer_read (myth_handle->file_transfer,
1.16 tmp_buffer, MYTHTV_BUFFER_SIZE - myth_handle->buffer_remain, TRUE);
1.17