[PATCH 2/7] Initialize 'klass' in |_dbus_type_reader_recurse| to NULL

Thomas Zimmermann <[email protected]>
Newsgroups gmane.comp.freedesktop.dbus
Message-ID <[email protected]>
Initializing 'klass' in |_dbus_type_reader_recurse| avoids a
compile-time warning about the variable being uninitialized.

Signed-off-by: Thomas Zimmermann <[email protected]>
---
 dbus/dbus-marshal-recursive.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dbus/dbus-marshal-recursive.c b/dbus/dbus-marshal-recursive.c
index bb39165..d49c4d3 100644
--- a/dbus/dbus-marshal-recursive.c
+++ b/dbus/dbus-marshal-recursive.c
@@ -989,8 +989,8 @@ void
 _dbus_type_reader_recurse (DBusTypeReader *reader,
                            DBusTypeReader *sub)
 {
-  const DBusTypeReaderClass *klass;
   int t;
+  const DBusTypeReaderClass *klass = NULL;
 
   t = _dbus_first_type_in_signature (reader->type_str, reader->type_pos);
 
-- 
2.7.4

_______________________________________________
dbus mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dbus
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.