summaryrefslogtreecommitdiff
path: root/src/lib/ecore/efl_io_buffered_stream.c
diff options
context:
space:
mode:
authorGustavo Sverzut Barbieri <barbieri@profusion.mobi>2016-12-19 21:43:56 -0200
committerGustavo Sverzut Barbieri <barbieri@profusion.mobi>2016-12-20 10:18:32 -0200
commit4d5105afebc2747fbf7da24cfaf93b933b18f086 (patch)
treeaee6145d6969f354e2fd2f1aa648ce58bea8b586 /src/lib/ecore/efl_io_buffered_stream.c
parent829d1d71fb019d566a6491212bd4ba2c04c527ce (diff)
efl_io_buffered_stream: if there is a copier, check if it's done.
Before we're exiting if there was nothing pending, but in some cases this was too aggressive as the copier's source may be alive (ie: not-EOS), however nothing was read to its internal buffer, thus no pending. Since the copier will track its source's EOS, just check if it's done.
Diffstat (limited to '')
-rw-r--r--src/lib/ecore/efl_io_buffered_stream.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/ecore/efl_io_buffered_stream.c b/src/lib/ecore/efl_io_buffered_stream.c
index 3b7b4d267b..ce6411bc5d 100644
--- a/src/lib/ecore/efl_io_buffered_stream.c
+++ b/src/lib/ecore/efl_io_buffered_stream.c
@@ -104,7 +104,7 @@ _efl_io_buffered_stream_sender_done(void *data, const Efl_Event *event EINA_UNUS
104 efl_ref(o); 104 efl_ref(o);
105 efl_event_callback_call(o, EFL_IO_BUFFERED_STREAM_EVENT_PROGRESS, NULL); 105 efl_event_callback_call(o, EFL_IO_BUFFERED_STREAM_EVENT_PROGRESS, NULL);
106 efl_event_callback_call(o, EFL_IO_BUFFERED_STREAM_EVENT_WRITE_FINISHED, NULL); 106 efl_event_callback_call(o, EFL_IO_BUFFERED_STREAM_EVENT_WRITE_FINISHED, NULL);
107 if ((pending == 0) || efl_io_copier_done_get(pd->receiver)) 107 if ((!pd->receiver) || efl_io_copier_done_get(pd->receiver))
108 { 108 {
109 if (!pd->is_finished) 109 if (!pd->is_finished)
110 { 110 {
@@ -294,7 +294,7 @@ _efl_io_buffered_stream_efl_io_reader_eos_set(Eo *o, Efl_Io_Buffered_Stream_Data
294 efl_event_callback_call(o, EFL_IO_BUFFERED_STREAM_EVENT_PROGRESS, NULL); 294 efl_event_callback_call(o, EFL_IO_BUFFERED_STREAM_EVENT_PROGRESS, NULL);
295 efl_event_callback_call(o, EFL_IO_READER_EVENT_EOS, NULL); 295 efl_event_callback_call(o, EFL_IO_READER_EVENT_EOS, NULL);
296 efl_event_callback_call(o, EFL_IO_BUFFERED_STREAM_EVENT_READ_FINISHED, NULL); 296 efl_event_callback_call(o, EFL_IO_BUFFERED_STREAM_EVENT_READ_FINISHED, NULL);
297 if ((pending == 0) || efl_io_copier_done_get(pd->sender)) 297 if ((!pd->sender) || efl_io_copier_done_get(pd->sender))
298 { 298 {
299 if (!pd->is_finished) 299 if (!pd->is_finished)
300 { 300 {