chiark / gitweb /
Bug #944: Replacement of a free() call by mfree()
[elogind.git] / src / libelogind / sd-bus / bus-message.c
index 3261154e04867feb13239550d5b8f9c87e1f3a7f..85882c1811d24ef7d8cb517e0600ba063158784a 100644 (file)
@@ -144,11 +144,7 @@ static void message_free(sd_bus_message *m) {
         if (m->iovec != m->iovec_fixed)
                 free(m->iovec);
 
-        if (m->destination_ptr) {
-                free(m->destination_ptr);
-                m->destination_ptr = NULL;
-        }
-
+        m->destination_ptr = mfree(m->destination_ptr);
         message_reset_containers(m);
         free(m->root_container.signature);
         free(m->root_container.offsets);