diff options
author | Steve Price <steve@FreeBSD.org> | 1998-11-09 01:09:25 +0000 |
---|---|---|
committer | Steve Price <steve@FreeBSD.org> | 1998-11-09 01:09:25 +0000 |
commit | 587c8c488f3060981d61b99187340c0a4a064594 (patch) | |
tree | 40af00e2f86a3a2cbb33c382a0341d5393025ae1 /mail/majordomo | |
parent | e5c1c88901518b48c2766085abe36b3fbc38fa89 (diff) |
Notes
Diffstat (limited to 'mail/majordomo')
-rw-r--r-- | mail/majordomo/scripts/createuser | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/mail/majordomo/scripts/createuser b/mail/majordomo/scripts/createuser index e75f9d4c71a8..f755b0b04d92 100644 --- a/mail/majordomo/scripts/createuser +++ b/mail/majordomo/scripts/createuser @@ -5,11 +5,6 @@ eval '(exit $?0)' && eval 'exec /usr/bin/perl -S $0 ${1+"$@"}' & eval 'exec /usr/bin/perl -S $0 $argv:q' if 0; -if( $> ) { - print "\nYou must be root to run this step!\n\n"; - exit 1; -} - if( ! -x "/usr/sbin/pw" ) { print "\nYou require the pw command, which was included in FreeBSD v2.2 builds\n"; print "as of Dec 9th 1996. If you don't have it, try looking in\n"; @@ -37,6 +32,13 @@ if( getgrnam( "majordom" ) ) { } } +if( $have_group && $have_user ) { + exit 0; +} elsif( $> ) { + print "\nYou must be root to run this step!\n\n"; + exit 1; +} + print "majordom user using uid $mjUID\n"; print "majordom user using gid $mjGID\n"; |