summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2011-10-19 18:42:18 -0400
committerMatthias Clasen <mclasen@redhat.com>2011-10-19 18:44:46 -0400
commite648f8220905b17632f7d4b2f16deac1b0aff7d0 (patch)
treead92fee1f490cffa689e1d378c9ce683d787a3ad
parentc4bc4be5fffeef911df7d6764c6dff5100bfa0b8 (diff)
downloadat-spi2-atk-e648f8220905b17632f7d4b2f16deac1b0aff7d0.tar.gz
Don't leave va_args dangling
spi_dbus_message_iter_append_struct has an early exit where it forgets to call va_end(). Harmless most of the time, but it upsets static analyzers. https://bugzilla.gnome.org/show_bug.cgi?id=662248
-rw-r--r--atk-adaptor/spi-dbus.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/atk-adaptor/spi-dbus.c b/atk-adaptor/spi-dbus.c
index b448510..e4fa49a 100644
--- a/atk-adaptor/spi-dbus.c
+++ b/atk-adaptor/spi-dbus.c
@@ -125,8 +125,8 @@ dbus_bool_t spi_dbus_message_iter_append_struct(DBusMessageIter *iter, ...)
ptr = va_arg(args, void *);
dbus_message_iter_append_basic(&iter_struct, type, ptr);
}
- if (!dbus_message_iter_close_container(iter, &iter_struct)) return FALSE;
va_end(args);
+ if (!dbus_message_iter_close_container(iter, &iter_struct)) return FALSE;
return TRUE;
}