summaryrefslogtreecommitdiff
path: root/usr.sbin/pppd
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>1996-01-07 09:55:34 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>1996-01-07 09:55:34 +0000
commit1c8890c1266d1212bfd536335869ddd9156c0f95 (patch)
tree22ec15200f04aa46c69e6be154af532e5597398d /usr.sbin/pppd
parentc5b76a7fa2d4c5de64ba37b96e6e24ca08ded6ba (diff)
pass a useful environment to ip-up/ip-down scripts; this is not a
security problem different fix than from banshee@gabriella.resort.com; netbsd pr#1866
Diffstat (limited to 'usr.sbin/pppd')
-rw-r--r--usr.sbin/pppd/main.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/usr.sbin/pppd/main.c b/usr.sbin/pppd/main.c
index 6a8b6988396..dac6ded2e63 100644
--- a/usr.sbin/pppd/main.c
+++ b/usr.sbin/pppd/main.c
@@ -18,7 +18,7 @@
*/
#ifndef lint
-static char rcsid[] = "$Id: main.c,v 1.2 1995/12/28 14:05:06 hannken Exp $";
+static char rcsid[] = "$Id: main.c,v 1.3 1996/01/07 09:55:33 deraadt Exp $";
#endif
#include <stdio.h>
@@ -863,7 +863,6 @@ run_program(prog, args, must_exist)
int must_exist;
{
int pid;
- char *nullenv[1];
pid = fork();
if (pid == -1) {
@@ -906,9 +905,7 @@ run_program(prog, args, must_exist)
/* SysV recommends a second fork at this point. */
- /* run the program; give it a null environment */
- nullenv[0] = NULL;
- execve(prog, args, nullenv);
+ execve(prog, args);
if (must_exist || errno != ENOENT)
syslog(LOG_WARNING, "Can't execute %s: %m", prog);
_exit(-1);