Terminate variable argument list with NULL, not 0.
This commit is contained in:
parent
5ac7f26c22
commit
0e46a38f38
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: modload.c,v 1.49 2004/10/27 19:36:31 peter Exp $ */
|
||||
/* $NetBSD: modload.c,v 1.50 2005/04/25 01:33:03 matt Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1993 Terrence R. Lambert.
|
||||
@ -34,7 +34,7 @@
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#ifndef lint
|
||||
__RCSID("$NetBSD: modload.c,v 1.49 2004/10/27 19:36:31 peter Exp $");
|
||||
__RCSID("$NetBSD: modload.c,v 1.50 2005/04/25 01:33:03 matt Exp $");
|
||||
#endif /* not lint */
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -512,12 +512,12 @@ main(int argc, char **argv)
|
||||
int cmajor = LKM_CHAR_MAJOR(sbuf.offset);
|
||||
(void)snprintf(arg3, sizeof(arg3), "%d", cmajor);
|
||||
(void)snprintf(arg4, sizeof(arg4), "%d", bmajor);
|
||||
execl(post, post, id, type, arg3, arg4, 0);
|
||||
execl(post, post, id, type, arg3, arg4, NULL);
|
||||
} else {
|
||||
char arg3[16];
|
||||
(void)snprintf(arg3, sizeof(arg3), "%ld",
|
||||
(long)sbuf.offset);
|
||||
execl(post, post, id, type, arg3, 0);
|
||||
execl(post, post, id, type, arg3, NULL);
|
||||
}
|
||||
err(16, "can't exec `%s'", post);
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: login_pam.c,v 1.7 2005/04/19 03:40:58 lukem Exp $ */
|
||||
/* $NetBSD: login_pam.c,v 1.8 2005/04/25 01:34:38 matt Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1980, 1987, 1988, 1991, 1993, 1994
|
||||
@ -40,7 +40,7 @@ __COPYRIGHT(
|
||||
#if 0
|
||||
static char sccsid[] = "@(#)login.c 8.4 (Berkeley) 4/2/94";
|
||||
#endif
|
||||
__RCSID("$NetBSD: login_pam.c,v 1.7 2005/04/19 03:40:58 lukem Exp $");
|
||||
__RCSID("$NetBSD: login_pam.c,v 1.8 2005/04/25 01:34:38 matt Exp $");
|
||||
#endif /* not lint */
|
||||
|
||||
/*
|
||||
@ -679,7 +679,7 @@ skip_auth:
|
||||
(void)strlcpy(tbuf + 1, (p = strrchr(pwd->pw_shell, '/')) ?
|
||||
p + 1 : pwd->pw_shell, sizeof(tbuf) - 1);
|
||||
|
||||
execlp(pwd->pw_shell, tbuf, 0);
|
||||
execlp(pwd->pw_shell, tbuf, NULL);
|
||||
err(EXIT_FAILURE, "%s", pwd->pw_shell);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user