← Commit list

d2bd7d8dd

Glenn L McGrath
Glenn L McGrath
2004-09-14
FAILED Duration: 26s

Subject

Patch from tito to add argument checking.

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

loginutils/addgroup.c+2 -2
@@ -148,7 +148,7 @@ int addgroup_main(int argc, char **argv)
/* get remaining args */
if(bb_getopt_ulflags(argc, argv, "g:", &group)) {
- gid = strtol(group, NULL, 10);
+ gid = bb_xgetlarg(group, 10, 0, LONG_MAX);
}
if (optind < argc) {
@@ -160,10 +160,10 @@ int addgroup_main(int argc, char **argv)
if (optind < argc) {
user = argv[optind];
- optind++;
} else {
user = "";
}
+
if_i_am_not_root();
/* werk */