[systemd-commits] src/shared

Kay Sievers kay at kemper.freedesktop.org
Sun Jul 15 06:35:20 PDT 2012


 src/shared/util.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 4a0ff4780d4e5e3927f1cf574e05979ddeef8ae1
Author: Kay Sievers <kay at vrfy.org>
Date:   Sun Jul 15 15:34:22 2012 +0200

    aquire_terminal(): fix uninitialized variable
    
    ./src/shared/util.c:2457:45: warning: 'r' may be used uninitialized in this function [-Wmaybe-uninitialized]

diff --git a/src/shared/util.c b/src/shared/util.c
index 845b4bf..cef6dbb 100644
--- a/src/shared/util.c
+++ b/src/shared/util.c
@@ -2385,7 +2385,7 @@ int acquire_terminal(
                 bool ignore_tiocstty_eperm,
                 usec_t timeout) {
 
-        int fd = -1, notify = -1, r, wd = -1;
+        int fd = -1, notify = -1, r = 0, wd = -1;
         usec_t ts = 0;
         struct sigaction sa_old, sa_new;
 



More information about the systemd-commits mailing list