Browse Source

Changed start-stop-daemon's --chuid user/group seperator to ':'

Ben Collins 27 years ago
parent
commit
8695d5aec4
2 changed files with 4 additions and 4 deletions
  1. 2 2
      utils/start-stop-daemon.8
  2. 2 2
      utils/start-stop-daemon.c

+ 2 - 2
utils/start-stop-daemon.8

@@ -123,8 +123,8 @@ Do not print informational messages; only display error messages.
 .TP
 .TP
 .I -c|--chuid
 .I -c|--chuid
 Change to this username/uid before starting the process. You can also
 Change to this username/uid before starting the process. You can also
-specify a group by appending a '.', then the group or gid in the same way
-as you would for the `chown' command (user.group). When using this option
+specify a group by appending a ':', then the group or gid in the same way
+as you would for the `chown' command (user:group). When using this option
 you must realize that the primary and suplimental groups are set as well,
 you must realize that the primary and suplimental groups are set as well,
 even if the `group' options is not specified. The group option is only for
 even if the `group' options is not specified. The group option is only for
 groups that the user isn't normally a member of (like adding per/process
 groups that the user isn't normally a member of (like adding per/process

+ 2 - 2
utils/start-stop-daemon.c

@@ -172,7 +172,7 @@ Usage:
 Options (at least one of --exec|--pidfile|--user is required):
 Options (at least one of --exec|--pidfile|--user is required):
   -x|--exec <executable>        program to start/check if it is running\n\
   -x|--exec <executable>        program to start/check if it is running\n\
   -p|--pidfile <pid-file>       pid file to check\n\
   -p|--pidfile <pid-file>       pid file to check\n\
-  -c|--chuid <name|uid[.group|gid]>
+  -c|--chuid <name|uid[:group|gid]>
   		change to this user/group before starting process\n\
   		change to this user/group before starting process\n\
   -u|--user <username>|<uid>    stop processes owned by this user\n\
   -u|--user <username>|<uid>    stop processes owned by this user\n\
   -n|--name <process-name>      stop processes with this name\n\
   -n|--name <process-name>      stop processes with this name\n\
@@ -312,7 +312,7 @@ parse_options(int argc, char * const *argv)
 			break;
 			break;
 		case 'c':  /* --chuid <username>|<uid> */
 		case 'c':  /* --chuid <username>|<uid> */
 			changeuser = strdup(optarg); /* because we need to modify */
 			changeuser = strdup(optarg); /* because we need to modify */
-			changegroup = strchr(changeuser, '.');
+			changegroup = strchr(changeuser, ':');
 			if (changegroup != NULL) {
 			if (changegroup != NULL) {
 				changegroup[0] = '\0';
 				changegroup[0] = '\0';
 				changegroup++;
 				changegroup++;