]> git.ipfire.org Git - thirdparty/dbus.git/commitdiff
Protect 'i' in _handle_inotify_watch by DBUS_ENABLE_VERBOSE_MODE
authorThomas Zimmermann <tdz@users.sourceforge.net>
Tue, 9 Aug 2016 16:19:56 +0000 (18:19 +0200)
committerSimon McVittie <simon.mcvittie@collabora.co.uk>
Thu, 11 Aug 2016 15:41:10 +0000 (16:41 +0100)
Signed-off-by: Thomas Zimmermann <tdz@users.sourceforge.net>
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=97282

bus/dir-watch-inotify.c

index ce19fdc8b12509167e32096b489d1076ddd5b533..a287f0ba56940c8eea37962e56b6d406511d4f92 100644 (file)
@@ -59,7 +59,9 @@ _handle_inotify_watch (DBusWatch *passed_watch, unsigned int flags, void *data)
 {
   char buffer[INOTIFY_BUF_LEN];
   ssize_t ret = 0;
+#ifdef DBUS_ENABLE_VERBOSE_MODE
   int i = 0;
+#endif
 
   ret = read (inotify_fd, buffer, INOTIFY_BUF_LEN);
   if (ret < 0)