summaryrefslogtreecommitdiffstats
path: root/usr.sbin/ppp/exec.c
diff options
context:
space:
mode:
authorbrian <brian@FreeBSD.org>2000-08-18 00:01:44 +0000
committerbrian <brian@FreeBSD.org>2000-08-18 00:01:44 +0000
commitbac59a32d06fce1477c920a3c8aad60f73ae9af9 (patch)
tree7688894f80a2ddf31d01f87489e92fffb7e1953c /usr.sbin/ppp/exec.c
parentc0049c3df2bfda77644542cc72cd5d7949841805 (diff)
downloadFreeBSD-src-bac59a32d06fce1477c920a3c8aad60f73ae9af9.zip
FreeBSD-src-bac59a32d06fce1477c920a3c8aad60f73ae9af9.tar.gz
Make -DNOSUID (or -DPPP_NOSUID) possible to build ppp without SUID
capabilities.
Diffstat (limited to 'usr.sbin/ppp/exec.c')
-rw-r--r--usr.sbin/ppp/exec.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/usr.sbin/ppp/exec.c b/usr.sbin/ppp/exec.c
index 898d143..1ca9665 100644
--- a/usr.sbin/ppp/exec.c
+++ b/usr.sbin/ppp/exec.c
@@ -137,7 +137,9 @@ exec_Create(struct physical *p)
close(pidpipe[0]);
close(fids[0]);
timer_TermService();
+#ifndef NOSUID
setuid(ID0realuid());
+#endif
child_status = 0;
switch ((pid = vfork())) {
OpenPOWER on IntegriCloud