summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGustavo Sverzut Barbieri <barbieri@profusion.mobi>2016-12-09 09:25:04 -0200
committerGustavo Sverzut Barbieri <barbieri@profusion.mobi>2016-12-09 13:47:04 -0200
commit47f9d06d0beff279355b312d417c2b04f3212b82 (patch)
tree1c5a511e201b90ec1937bf8f0e726ff7ac2024cd
parentb2bbc1c1885bf5a47dbea5d8714afbb8bd0d8540 (diff)
efl_io_buffered_stream: del inner_io if we're the parent.
This is a nice convenience if inner_io was reparented to the wrapper.
Diffstat (limited to '')
-rw-r--r--src/lib/ecore/efl_io_buffered_stream.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/lib/ecore/efl_io_buffered_stream.c b/src/lib/ecore/efl_io_buffered_stream.c
index 6d58e67395..5930fca902 100644
--- a/src/lib/ecore/efl_io_buffered_stream.c
+++ b/src/lib/ecore/efl_io_buffered_stream.c
@@ -175,7 +175,10 @@ _efl_io_buffered_stream_efl_object_destructor(Eo *o, Efl_Io_Buffered_Stream_Data
175 if (pd->inner_io) 175 if (pd->inner_io)
176 { 176 {
177 efl_event_callback_array_del(pd->inner_io, _efl_io_buffered_stream_inner_io_cbs(), o); 177 efl_event_callback_array_del(pd->inner_io, _efl_io_buffered_stream_inner_io_cbs(), o);
178 efl_unref(pd->inner_io); /* do not del, just take our ref */ 178 if (efl_parent_get(pd->inner_io) == o)
179 efl_parent_set(pd->inner_io, NULL);
180 else
181 efl_unref(pd->inner_io); /* do not del, just take our ref */
179 pd->inner_io = NULL; 182 pd->inner_io = NULL;
180 } 183 }
181 184