summaryrefslogtreecommitdiff
path: root/loginutils/adduser.c
diff options
context:
space:
mode:
authorMike Frysinger2005-11-15 05:53:00 +0000
committerMike Frysinger2005-11-15 05:53:00 +0000
commit4ee2eee2fcd6da772abb572c92cfa231517ae65c (patch)
treedf157bd5b77195b9e93830748bb7d49c689abbff /loginutils/adduser.c
parent79e1cab0d16468b114ea93e53eb63b76b5d39b62 (diff)
downloadbusybox-4ee2eee2fcd6da772abb572c92cfa231517ae65c.zip
busybox-4ee2eee2fcd6da772abb572c92cfa231517ae65c.tar.gz
Quote the user we pass to addgroup so funky chars are preserved. Fix by dragan_marinkovic in Bug 544
Diffstat (limited to 'loginutils/adduser.c')
-rw-r--r--loginutils/adduser.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/loginutils/adduser.c b/loginutils/adduser.c
index 1630c72..5ff0cd9 100644
--- a/loginutils/adduser.c
+++ b/loginutils/adduser.c
@@ -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);
}