[libglnx] fix bug found by -Wmaybe-uninitialized



commit 5309e363aa30d2108a264ae35d8d870ee3e0c443
Author: Jonathan Lebon <jlebon redhat com>
Date:   Thu Mar 2 13:55:30 2017 -0500

    fix bug found by -Wmaybe-uninitialized

 tests/test-libglnx-xattrs.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/tests/test-libglnx-xattrs.c b/tests/test-libglnx-xattrs.c
index 21bdbdb..0b21133 100644
--- a/tests/test-libglnx-xattrs.c
+++ b/tests/test-libglnx-xattrs.c
@@ -192,7 +192,7 @@ xattr_thread (gpointer data)
   GError **error = &local_error;
   struct XattrWorker *worker = data;
   guint64 end_time = g_get_monotonic_time () + XATTR_THREAD_RUN_TIME_USECS;
-  guint n_read;
+  guint n_read = 0;
 
   while (g_get_monotonic_time () < end_time)
     {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]