Przeglądaj źródła

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

Ben Collins 27 lat temu
rodzic
commit
8695d5aec4
2 zmienionych plików z 4 dodań i 4 usunięć
  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
 .I -c|--chuid
 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,
 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

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

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