obexd: Clean up unneeded list in src/obex.c 87/204887/1
authorERAMOTO Masaya <eramoto.masaya@jp.fujitsu.com>
Tue, 23 Jan 2018 09:45:34 +0000 (18:45 +0900)
committerAmit Purwar <amit.purwar@samsung.com>
Mon, 15 Apr 2019 03:21:42 +0000 (08:51 +0530)
Cleans up the sessions list which has been unneeded by commit 8572afb4
("obexd: Make use of transport drivers and some cleanups").

Change-Id: Ie06072fa6d052bd7e5bdc824e8250362bd914cae
Signed-off-by: Amit Purwar <amit.purwar@samsung.com>
obexd/src/obex.c

index 33976dc..98650ba 100644 (file)
@@ -58,8 +58,6 @@
 #include "service.h"
 #include "transport.h"
 
-static GSList *sessions = NULL;
-
 typedef struct {
        uint8_t  version;
        uint8_t  flags;
@@ -237,8 +235,6 @@ static void os_reset_session(struct obex_session *os)
 
 static void obex_session_free(struct obex_session *os)
 {
-       sessions = g_slist_remove(sessions, os);
-
        if (os->io) {
                g_io_channel_shutdown(os->io, TRUE, NULL);
                g_io_channel_unref(os->io);
@@ -1166,8 +1162,6 @@ int obex_session_start(GIOChannel *io, uint16_t tx_mtu, uint16_t rx_mtu,
        obex_getsockname(os, &os->src);
        obex_getpeername(os, &os->dst);
 
-       sessions = g_slist_prepend(sessions, os);
-
        return 0;
 }