]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
sulogin: keep initialization more robust
authorKarel Zak <kzak@redhat.com>
Fri, 12 Feb 2016 10:21:50 +0000 (11:21 +0100)
committerKarel Zak <kzak@redhat.com>
Fri, 12 Feb 2016 10:21:50 +0000 (11:21 +0100)
Signed-off-by: Karel Zak <kzak@redhat.com>
login-utils/sulogin.c

index 4b1e44b070ac86684c2761439db5eb1dc4c4b75d..643712ff561c648274e9da24645344b14c37b3b0 100644 (file)
@@ -857,7 +857,7 @@ int main(int argc, char **argv)
        struct console *con;
        char *tty = NULL;
        struct passwd *pwd;
-       struct timespec sigwait = {0, 50000000};
+       struct timespec sigwait = { .tv_sec = 0, .tv_nsec = 50000000 };
        siginfo_t status = {};
        sigset_t set = {};
        int c, reconnect = 0;