summaryrefslogtreecommitdiff
path: root/src/lib/ecore_con
diff options
context:
space:
mode:
authorMarcel Hollerbach <mail@marcel-hollerbach.de>2019-03-19 16:29:34 -0400
committerMike Blumenkrantz <zmike@samsung.com>2019-03-19 16:29:34 -0400
commit06863ac18ec3547270e970df8472a590fb0438aa (patch)
treef74d4810b2857ba4ccfc62256def3da8b38f76ad /src/lib/ecore_con
parentbb0290edbe1b75a82293fc9774e96dd412bdd3ff (diff)
efl_net: resolve cases where we passed something as event_info
Summary: but the event was annotated to *not* contain any event_info. Reviewers: cedric, segfaultxavi, zmike Reviewed By: zmike Subscribers: #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D8411
Diffstat (limited to 'src/lib/ecore_con')
-rw-r--r--src/lib/ecore_con/efl_net_dialer_simple.c36
-rw-r--r--src/lib/ecore_con/efl_net_server_simple.c4
2 files changed, 8 insertions, 32 deletions
diff --git a/src/lib/ecore_con/efl_net_dialer_simple.c b/src/lib/ecore_con/efl_net_dialer_simple.c
index 775621a..2944d76 100644
--- a/src/lib/ecore_con/efl_net_dialer_simple.c
+++ b/src/lib/ecore_con/efl_net_dialer_simple.c
@@ -29,33 +29,6 @@ typedef struct
29 29
30#define MY_CLASS EFL_NET_DIALER_SIMPLE_CLASS 30#define MY_CLASS EFL_NET_DIALER_SIMPLE_CLASS
31 31
32static void
33_efl_net_dialer_simple_inner_io_resolved(void *data, const Efl_Event *event)
34{
35 Eo *o = data;
36 efl_event_callback_call(o, EFL_NET_DIALER_EVENT_DIALER_RESOLVED, event->info);
37}
38
39static void
40_efl_net_dialer_simple_inner_io_error(void *data, const Efl_Event *event)
41{
42 Eo *o = data;
43 efl_event_callback_call(o, EFL_NET_DIALER_EVENT_DIALER_ERROR, event->info);
44}
45
46static void
47_efl_net_dialer_simple_inner_io_connected(void *data, const Efl_Event *event)
48{
49 Eo *o = data;
50
51 efl_event_callback_call(o, EFL_NET_DIALER_EVENT_DIALER_CONNECTED, event->info);
52}
53
54EFL_CALLBACKS_ARRAY_DEFINE(_efl_net_dialer_simple_inner_io_cbs,
55 { EFL_NET_DIALER_EVENT_DIALER_RESOLVED, _efl_net_dialer_simple_inner_io_resolved },
56 { EFL_NET_DIALER_EVENT_DIALER_ERROR, _efl_net_dialer_simple_inner_io_error },
57 { EFL_NET_DIALER_EVENT_DIALER_CONNECTED, _efl_net_dialer_simple_inner_io_connected });
58
59EOLIAN static Efl_Object * 32EOLIAN static Efl_Object *
60_efl_net_dialer_simple_efl_object_finalize(Eo *o, Efl_Net_Dialer_Simple_Data *pd) 33_efl_net_dialer_simple_efl_object_finalize(Eo *o, Efl_Net_Dialer_Simple_Data *pd)
61{ 34{
@@ -94,7 +67,9 @@ _efl_net_dialer_simple_efl_object_invalidate(Eo *o, Efl_Net_Dialer_Simple_Data *
94 inner_io = efl_io_buffered_stream_inner_io_get(o); 67 inner_io = efl_io_buffered_stream_inner_io_get(o);
95 if (inner_io) 68 if (inner_io)
96 { 69 {
97 efl_event_callback_array_del(inner_io, _efl_net_dialer_simple_inner_io_cbs(), o); 70 efl_event_callback_forwarder_del(inner_io, EFL_NET_DIALER_EVENT_DIALER_ERROR, o);
71 efl_event_callback_forwarder_del(inner_io, EFL_NET_DIALER_EVENT_DIALER_CONNECTED, o);
72 efl_event_callback_forwarder_del(inner_io, EFL_NET_DIALER_EVENT_DIALER_CONNECTED, o);
98 if (efl_parent_get(inner_io) == o) 73 if (efl_parent_get(inner_io) == o)
99 efl_parent_set(inner_io, NULL); 74 efl_parent_set(inner_io, NULL);
100 } 75 }
@@ -122,8 +97,9 @@ _efl_net_dialer_simple_efl_io_buffered_stream_inner_io_set(Eo *o, Efl_Net_Dialer
122{ 97{
123 EINA_SAFETY_ON_FALSE_RETURN(efl_isa(io, EFL_NET_DIALER_INTERFACE)); 98 EINA_SAFETY_ON_FALSE_RETURN(efl_isa(io, EFL_NET_DIALER_INTERFACE));
124 efl_io_buffered_stream_inner_io_set(efl_super(o, MY_CLASS), io); 99 efl_io_buffered_stream_inner_io_set(efl_super(o, MY_CLASS), io);
125 efl_event_callback_array_add(io, _efl_net_dialer_simple_inner_io_cbs(), o); 100 efl_event_callback_forwarder_add(io, EFL_NET_DIALER_EVENT_DIALER_ERROR, o);
126 101 efl_event_callback_forwarder_add(io, EFL_NET_DIALER_EVENT_DIALER_CONNECTED, o);
102 efl_event_callback_forwarder_add(io, EFL_NET_DIALER_EVENT_DIALER_CONNECTED, o);
127 /* apply pending dialer values */ 103 /* apply pending dialer values */
128 if (pd->pending.proxy_url) 104 if (pd->pending.proxy_url)
129 { 105 {
diff --git a/src/lib/ecore_con/efl_net_server_simple.c b/src/lib/ecore_con/efl_net_server_simple.c
index 46924fa..6ae83dd 100644
--- a/src/lib/ecore_con/efl_net_server_simple.c
+++ b/src/lib/ecore_con/efl_net_server_simple.c
@@ -113,10 +113,10 @@ _efl_net_server_simple_inner_server_error(void *data, const Efl_Event *event)
113} 113}
114 114
115static void 115static void
116_efl_net_server_simple_inner_server_serving(void *data, const Efl_Event *event) 116_efl_net_server_simple_inner_server_serving(void *data, const Efl_Event *event EINA_UNUSED)
117{ 117{
118 Eo *o = data; 118 Eo *o = data;
119 efl_event_callback_call(o, EFL_NET_SERVER_EVENT_SERVING, event->info); 119 efl_event_callback_call(o, EFL_NET_SERVER_EVENT_SERVING, NULL);
120} 120}
121 121
122EFL_CALLBACKS_ARRAY_DEFINE(_efl_net_server_simple_inner_server_cbs, 122EFL_CALLBACKS_ARRAY_DEFINE(_efl_net_server_simple_inner_server_cbs,