aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2007-08-20 09:08:06 +0000
committerRoy Marples <roy@marples.name>2007-08-20 09:08:06 +0000
commit9ea8afb2002d59acc792189c4992541e04686215 (patch)
tree803b51ef5d9b0b2f787089eab3e6434b57b9dabd
parent0963e067664119c6ae352167698e1fc8fc8f02d5 (diff)
No point in having to lots of get the user code.
-rw-r--r--src/start-stop-daemon.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/src/start-stop-daemon.c b/src/start-stop-daemon.c
index d1a3d494..51e4dee8 100644
--- a/src/start-stop-daemon.c
+++ b/src/start-stop-daemon.c
@@ -565,6 +565,7 @@ int start_stop_daemon (int argc, char **argv)
background = true;
break;
+ case 'u': /* --user <username>|<uid> */
case 'c': /* --chuid <username>|<uid> */
{
char *p = optarg;
@@ -646,16 +647,6 @@ int start_stop_daemon (int argc, char **argv)
test = true;
break;
- case 'u': /* --user <username>|<uid> */
- if (sscanf (optarg, "%d", &tid) != 1) {
- struct passwd *pw = getpwnam (optarg);
- if (! pw)
- eerrorx ("%s: user `%s' not found", applet, optarg);
- uid = pw->pw_uid;
- } else
- uid = tid;
- break;
-
case 'r': /* --chroot /new/root */
ch_root = optarg;
break;