summaryrefslogtreecommitdiff
path: root/src/lib/ecore_con
diff options
context:
space:
mode:
authorSrivardhan Hebbar <sri.hebbar@samsung.com>2015-04-28 14:13:30 +0200
committerCedric BAIL <cedric@osg.samsung.com>2015-04-28 14:14:07 +0200
commit5af99bdc7a3fdd71466e11eea6f21c1ca9c1d386 (patch)
tree02f6dc12a12db57688f249933ada3eee7381b950 /src/lib/ecore_con
parentfbc51e0432bceb727c3212bc1ec344cf661185cf (diff)
ecore_con: fix double free issue in ecore_con_eet.
Summary: While creating ecore_con_eet_server, if client is not set to false, then while deleting, it is checking for client and it is by default not false. So set it. ecore_con_reply object is being deleted twice. So removed code to delete the reply object as it would be deleted after the callback. Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com> Reviewers: cedric Subscribers: cedric Maniphest Tasks: T2372 Differential Revision: https://phab.enlightenment.org/D2445 Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
Diffstat (limited to 'src/lib/ecore_con')
-rw-r--r--src/lib/ecore_con/ecore_con_eet.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/ecore_con/ecore_con_eet.c b/src/lib/ecore_con/ecore_con_eet.c
index c6195b563a..eb335ceba4 100644
--- a/src/lib/ecore_con/ecore_con_eet.c
+++ b/src/lib/ecore_con/ecore_con_eet.c
@@ -452,6 +452,7 @@ ecore_con_eet_server_new(Ecore_Con_Server *server)
452 r = calloc(1, sizeof (Ecore_Con_Eet)); 452 r = calloc(1, sizeof (Ecore_Con_Eet));
453 if (!r) return NULL; 453 if (!r) return NULL;
454 454
455 r->client = EINA_FALSE;
455 r->server = server; 456 r->server = server;
456 r->handler_add = ecore_event_handler_add(ECORE_CON_EVENT_CLIENT_ADD, 457 r->handler_add = ecore_event_handler_add(ECORE_CON_EVENT_CLIENT_ADD,
457 (Ecore_Event_Handler_Cb)_ecore_con_eet_server_connected, r); 458 (Ecore_Event_Handler_Cb)_ecore_con_eet_server_connected, r);
@@ -511,7 +512,6 @@ ecore_con_eet_server_free(Ecore_Con_Eet *r)
511 { 512 {
512 _ecore_con_eet_reply_cleanup(r->u.client.r); 513 _ecore_con_eet_reply_cleanup(r->u.client.r);
513 eet_connection_close(r->u.client.r->econn, NULL); 514 eet_connection_close(r->u.client.r->econn, NULL);
514 free(r->u.client.r);
515 } 515 }
516 EINA_LIST_FREE(r->u.client.server_connect_callbacks, s) 516 EINA_LIST_FREE(r->u.client.server_connect_callbacks, s)
517 free(s); 517 free(s);