kdbus: Remove the unnecessary code that unlink the reply twice. 93/100393/1
authorINSUN PYO <insun.pyo@samsung.com>
Thu, 24 Nov 2016 07:03:42 +0000 (16:03 +0900)
committerINSUN PYO <insun.pyo@samsung.com>
Mon, 28 Nov 2016 04:46:09 +0000 (20:46 -0800)
In sync call situation, kdbus_conn_reply() calls kdbus_reply_unlink(reply).
Then, kdbus_conn_entry_sync_attach() also calls kdbus_reply_unlink(reply_wake),
so it is called twice. Even it has no problems because kdbus_reply_unlink()
does't free twice, but it is unnecessary.

Signed-off-by: INSUN PYO <insun.pyo@samsung.com>
Change-Id: Ia2b3552ee2e6a49ff97bb9d8f6e62964fe6d2cbf
(cherry picked from commit 81c82865a0f660cf3d552ca5879f674222e7060a)

ipc/kdbus/connection.c

index 2dd907e4288b679e1d32b6627fdcb14522dfc4ea..02deba366839b9814252ea3b6ec26eb5521a54ef 100644 (file)
@@ -871,7 +871,6 @@ static int kdbus_conn_entry_sync_attach(struct kdbus_conn *conn_dst,
                remote_ret = -EREMOTEIO;
 
        kdbus_sync_reply_wakeup(reply_wake, remote_ret);
-       kdbus_reply_unlink(reply_wake);
        mutex_unlock(&reply_wake->reply_dst->lock);
 
        return ret;