kdbus: fix NULL free on TIZEN code path for sending unmatched replies
authorKonrad Lipinski <konrad.l@samsung.com>
Tue, 20 Sep 2016 10:27:52 +0000 (12:27 +0200)
committerKonrad Lipinski <konrad.l@samsung.com>
Tue, 20 Sep 2016 10:27:52 +0000 (12:27 +0200)
ipc/kdbus/connection.c

index fbfaaddd043d6167078a4986e1000ed2962257bf..9dcf7f1a89dc84d1450345320a4c556a975fbf37 100644 (file)
@@ -1049,7 +1049,8 @@ static int kdbus_conn_reply(struct kdbus_conn *src,
 
 exit:
        up_read(&bus->name_registry.rwlock);
-       if (dontWant) /* if the other side is no longer interested, we have to free the reply ourselves */
+       /* NOTE: check for reply being non-NULL only necessary on TIZEN because replies are not being filtered */
+       if (dontWant && reply) /* if the other side is no longer interested, we have to free the reply ourselves */
                kdbus_reply_free(reply);
        return ret;
 }