aboutsummaryrefslogtreecommitdiff
path: root/libbb/appletlib.c
diff options
context:
space:
mode:
authorRon Yorston <rmy@pobox.com>2012-03-21 20:53:50 +0000
committerRon Yorston <rmy@pobox.com>2012-03-21 20:53:50 +0000
commitf6bad5ef766b0447158e3de2f55c35f1f6cecb58 (patch)
treef5ec7ac45234c25794c97f87e9a6daa8a551e57c /libbb/appletlib.c
parent72394258b6509b40e0fa08594ac86215a558dfd8 (diff)
parent8d0e0cdadf726beab28ccdc7d69738c1534e1f74 (diff)
downloadbusybox-w32-f6bad5ef766b0447158e3de2f55c35f1f6cecb58.tar.gz
busybox-w32-f6bad5ef766b0447158e3de2f55c35f1f6cecb58.tar.bz2
busybox-w32-f6bad5ef766b0447158e3de2f55c35f1f6cecb58.zip
Merge commit '8d0e0cdadf726beab28ccdc7d69738c1534e1f74' into merge
Conflicts: include/platform.h libbb/Kbuild.src libbb/messages.c
Diffstat (limited to 'libbb/appletlib.c')
-rw-r--r--libbb/appletlib.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libbb/appletlib.c b/libbb/appletlib.c
index b1c772cf3..4e32414b4 100644
--- a/libbb/appletlib.c
+++ b/libbb/appletlib.c
@@ -574,12 +574,12 @@ static void check_suid(int applet_no)
574# endif 574# endif
575 check_need_suid: 575 check_need_suid:
576# endif 576# endif
577 if (APPLET_SUID(applet_no) == _BB_SUID_REQUIRE) { 577 if (APPLET_SUID(applet_no) == BB_SUID_REQUIRE) {
578 /* Real uid is not 0. If euid isn't 0 too, suid bit 578 /* Real uid is not 0. If euid isn't 0 too, suid bit
579 * is most probably not set on our executable */ 579 * is most probably not set on our executable */
580 if (geteuid()) 580 if (geteuid())
581 bb_error_msg_and_die("must be suid to work properly"); 581 bb_error_msg_and_die("must be suid to work properly");
582 } else if (APPLET_SUID(applet_no) == _BB_SUID_DROP) { 582 } else if (APPLET_SUID(applet_no) == BB_SUID_DROP) {
583 xsetgid(rgid); /* drop all privileges */ 583 xsetgid(rgid); /* drop all privileges */
584 xsetuid(ruid); 584 xsetuid(ruid);
585 } 585 }