mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-12 17:37:53 +03:00
id: Remove weird commas from output
This commit is contained in:
parent
f558c8e36a
commit
d4b4883d55
Notes:
sideshowbarker
2024-07-19 10:22:37 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/d4b4883d550
@ -100,7 +100,7 @@ bool print_full_id_list()
|
||||
struct passwd* pw = getpwuid(uid);
|
||||
struct group* gr = getgrgid(gid);
|
||||
|
||||
printf("uid=%u(%s), gid=%u(%s)", uid, pw ? pw->pw_name : "n/a", gid, gr ? gr->gr_name : "n/a");
|
||||
printf("uid=%u(%s) gid=%u(%s)", uid, pw ? pw->pw_name : "n/a", gid, gr ? gr->gr_name : "n/a");
|
||||
|
||||
int extra_gid_count = getgroups(0, nullptr);
|
||||
if (extra_gid_count) {
|
||||
@ -110,7 +110,7 @@ bool print_full_id_list()
|
||||
perror("\ngetgroups");
|
||||
return false;
|
||||
}
|
||||
printf(", groups=");
|
||||
printf(" groups=");
|
||||
for (int g = 0; g < extra_gid_count; ++g) {
|
||||
auto* gr = getgrgid(extra_gids[g]);
|
||||
if (gr)
|
||||
|
Loading…
Reference in New Issue
Block a user