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 14:46:37 -0200
committerGustavo Sverzut Barbieri <barbieri@profusion.mobi>2016-12-19 15:30:56 -0200
commit25a9e1d886054d3907fb43e3682525b1a3901209 (patch)
tree1b231755171bb24e4353183a907cf242deab9c23 /src/lib/ecore/efl_io_buffered_stream.c
parent6f9deb976a9774a14636cb3131743245347b2dd4 (diff)
Efl.Io.{Queue,Buffer,Buffered_Stream}: slice_get is now a property.
Previously we couldn't return a slice, instead required the user to pass a slice and we'd fill it since Eolian couldn't generate fallbacks for structures. Since @q66 fixed eolian, we can now return the structure itself as initially wanted, ditching some TODO from the code.
Diffstat (limited to '')
-rw-r--r--src/lib/ecore/efl_io_buffered_stream.c20
1 files changed, 8 insertions, 12 deletions
diff --git a/src/lib/ecore/efl_io_buffered_stream.c b/src/lib/ecore/efl_io_buffered_stream.c
index 82de769bf0..a54d125b2d 100644
--- a/src/lib/ecore/efl_io_buffered_stream.c
+++ b/src/lib/ecore/efl_io_buffered_stream.c
@@ -533,19 +533,15 @@ _efl_io_buffered_stream_progress_get(Eo *o EINA_UNUSED, Efl_Io_Buffered_Stream_D
533 if (pw) *pw = w; 533 if (pw) *pw = w;
534} 534}
535 535
536EOLIAN static Eina_Bool 536EOLIAN static Eina_Slice
537_efl_io_buffered_stream_slice_get(Eo *o EINA_UNUSED, Efl_Io_Buffered_Stream_Data *pd, Eina_Slice *slice) 537_efl_io_buffered_stream_slice_get(Eo *o EINA_UNUSED, Efl_Io_Buffered_Stream_Data *pd)
538{ 538{
539 if (!pd->incoming) 539 Eina_Slice slice = { };
540 { 540
541 if (slice) 541 if (pd->incoming)
542 { 542 slice = efl_io_queue_slice_get(pd->incoming);
543 slice->mem = NULL; 543
544 slice->len = 0; 544 return slice;
545 }
546 return EINA_FALSE;
547 }
548 return efl_io_queue_slice_get(pd->incoming, slice);
549} 545}
550 546
551EOLIAN static void 547EOLIAN static void