summaryrefslogtreecommitdiff
path: root/usr.bin
diff options
context:
space:
mode:
authormrg <mrg@NetBSD.org>2006-05-11 00:22:52 +0000
committermrg <mrg@NetBSD.org>2006-05-11 00:22:52 +0000
commit4bc6feceb6ebda151502af1a7ed21ae8c0fad3ac (patch)
tree42a0edee6a5c4c8473190df03bae288bbae562b9 /usr.bin
parent8e969ac07006af925e6fbcbf1a1cb17064ef921e (diff)
end the argument list to exec*(3) with a NULL instead of a bare '0', as
the latter isn't a pointer context in these varargs functions.
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/rdist/server.c6
-rw-r--r--usr.bin/telnet/commands.c8
-rw-r--r--usr.bin/tip/cmds.c10
-rw-r--r--usr.bin/tn3270/sys_curses/system.c6
4 files changed, 15 insertions, 15 deletions
diff --git a/usr.bin/rdist/server.c b/usr.bin/rdist/server.c
index 3cff3dd0b69..3ce542f700d 100644
--- a/usr.bin/rdist/server.c
+++ b/usr.bin/rdist/server.c
@@ -1,4 +1,4 @@
-/* $NetBSD: server.c,v 1.28 2004/08/06 15:50:02 mycroft Exp $ */
+/* $NetBSD: server.c,v 1.29 2006/05/11 00:22:52 mrg Exp $ */
/*
* Copyright (c) 1983, 1993
@@ -34,7 +34,7 @@
#if 0
static char sccsid[] = "@(#)server.c 8.1 (Berkeley) 6/9/93";
#else
-__RCSID("$NetBSD: server.c,v 1.28 2004/08/06 15:50:02 mycroft Exp $");
+__RCSID("$NetBSD: server.c,v 1.29 2006/05/11 00:22:52 mrg Exp $");
#endif
#endif /* not lint */
@@ -1388,7 +1388,7 @@ dospecial(char *cmd)
(void) close(fd[1]);
setgid(groupid);
setuid(userid);
- execl(_PATH_BSHELL, "sh", "-c", cmd, 0);
+ execl(_PATH_BSHELL, "sh", "-c", cmd, NULL);
_exit(127);
}
(void) close(fd[1]);
diff --git a/usr.bin/telnet/commands.c b/usr.bin/telnet/commands.c
index ff4261bbdae..bc1d37cfb86 100644
--- a/usr.bin/telnet/commands.c
+++ b/usr.bin/telnet/commands.c
@@ -1,4 +1,4 @@
-/* $NetBSD: commands.c,v 1.65 2006/05/05 00:03:22 rpaulo Exp $ */
+/* $NetBSD: commands.c,v 1.66 2006/05/11 00:25:46 mrg Exp $ */
/*
* Copyright (C) 1997 and 1998 WIDE Project.
@@ -63,7 +63,7 @@
#if 0
static char sccsid[] = "@(#)commands.c 8.4 (Berkeley) 5/30/95";
#else
-__RCSID("$NetBSD: commands.c,v 1.65 2006/05/05 00:03:22 rpaulo Exp $");
+__RCSID("$NetBSD: commands.c,v 1.66 2006/05/11 00:25:46 mrg Exp $");
#endif
#endif /* not lint */
@@ -1388,9 +1388,9 @@ shell(int argc, char *argv[])
else
shellname++;
if (argc > 1)
- execl(shellp, shellname, "-c", &saveline[1], 0);
+ execl(shellp, shellname, "-c", &saveline[1], NULL);
else
- execl(shellp, shellname, 0);
+ execl(shellp, shellname, NULL);
perror("execl");
_exit(1);
}
diff --git a/usr.bin/tip/cmds.c b/usr.bin/tip/cmds.c
index 23b27ecf701..0ba0156ffc5 100644
--- a/usr.bin/tip/cmds.c
+++ b/usr.bin/tip/cmds.c
@@ -1,4 +1,4 @@
-/* $NetBSD: cmds.c,v 1.28 2006/04/03 16:13:34 tls Exp $ */
+/* $NetBSD: cmds.c,v 1.29 2006/05/11 00:22:53 mrg Exp $ */
/*
* Copyright (c) 1983, 1993
@@ -34,7 +34,7 @@
#if 0
static char sccsid[] = "@(#)cmds.c 8.1 (Berkeley) 6/6/93";
#endif
-__RCSID("$NetBSD: cmds.c,v 1.28 2006/04/03 16:13:34 tls Exp $");
+__RCSID("$NetBSD: cmds.c,v 1.29 2006/05/11 00:22:53 mrg Exp $");
#endif /* not lint */
#include "tip.h"
@@ -586,7 +586,7 @@ shell(char dummy)
cp = value(SHELL);
else
cp++;
- execl(value(SHELL), cp, 0);
+ execl(value(SHELL), cp, NULL);
fprintf(stderr, "\r\n");
err(1, "can't execl");
/* NOTREACHED */
@@ -687,7 +687,7 @@ execute(char *s)
cp = value(SHELL);
else
cp++;
- execl(value(SHELL), cp, "-c", s, 0);
+ execl(value(SHELL), cp, "-c", s, NULL);
}
int
@@ -875,7 +875,7 @@ expand(char name[])
dup(pivec[1]);
close(pivec[1]);
close(2);
- execl(Shell, Shell, "-c", cmdbuf, 0);
+ execl(Shell, Shell, "-c", cmdbuf, NULL);
_exit(1);
}
if (mypid == -1) {
diff --git a/usr.bin/tn3270/sys_curses/system.c b/usr.bin/tn3270/sys_curses/system.c
index 499b472f132..812538da60f 100644
--- a/usr.bin/tn3270/sys_curses/system.c
+++ b/usr.bin/tn3270/sys_curses/system.c
@@ -1,4 +1,4 @@
-/* $NetBSD: system.c,v 1.18 2006/04/30 23:43:31 christos Exp $ */
+/* $NetBSD: system.c,v 1.19 2006/05/11 00:25:46 mrg Exp $ */
/*-
* Copyright (c) 1988 The Regents of the University of California.
@@ -34,7 +34,7 @@
#if 0
static char sccsid[] = "@(#)system.c 4.5 (Berkeley) 4/26/91";
#else
-__RCSID("$NetBSD: system.c,v 1.18 2006/04/30 23:43:31 christos Exp $");
+__RCSID("$NetBSD: system.c,v 1.19 2006/05/11 00:25:46 mrg Exp $");
#endif
#endif /* not lint */
@@ -748,7 +748,7 @@ char *argv[];
char *cmdname;
cmdname = getenv("SHELL");
- execlp(cmdname, cmdname, 0);
+ execlp(cmdname, cmdname, NULL);
perror("Exec'ing new shell");
_exit(1);
} else {