Quote the user we pass to addgroup so funky chars are preserved. Fix by dragan_marinkovic in Bug 544

1_1_stable
Mike Frysinger 2005-11-15 05:53:00 +00:00
parent 79e1cab0d1
commit 4ee2eee2fc
1 changed files with 1 additions and 1 deletions

View File

@ -117,7 +117,7 @@ static void addgroup_wrapper(const char *login, gid_t gid)
{
char *cmd;
cmd = bb_xasprintf("addgroup -g %d %s", gid, login);
cmd = bb_xasprintf("addgroup -g %d \"%s\"", gid, login);
system(cmd);
free(cmd);
}