]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
login: Use pid_t for child_pid
authorTobias Stoeckmann <tobias@stoeckmann.org>
Tue, 19 Sep 2023 18:45:40 +0000 (20:45 +0200)
committerKarel Zak <kzak@redhat.com>
Fri, 24 Nov 2023 09:44:11 +0000 (10:44 +0100)
Since child_pid keeps track of a PID, it should be of type pid_t
and not of type int.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
login-utils/login.c

index a8a76f38859b69980f2e4f8465c3351cb71e7725..1812b901797318af921e7ea4b24e3c98582abfb2 100644 (file)
@@ -138,7 +138,7 @@ struct login_context {
                        keep_env:1;     /* login -p */
 };
 
-static int child_pid = 0;
+static pid_t child_pid = 0;
 static volatile sig_atomic_t got_sig = 0;
 static char *timeout_msg;