Skip to content

Commit

Permalink
sysutils/accountsservice: Fix a bug with the User.SetAccountType() me…
Browse files Browse the repository at this point in the history
…thod.

This call was removing a user from all its groups.

Sponsored by:	Serenity Cybersecurity, LLC
  • Loading branch information
arrowd committed Jun 27, 2023
1 parent 86d2df3 commit 2352c3f
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
2 changes: 1 addition & 1 deletion sysutils/accountsservice/Makefile
@@ -1,6 +1,6 @@
PORTNAME= accountsservice
PORTVERSION= 0.6.55
PORTREVISION= 4
PORTREVISION= 5
CATEGORIES= sysutils devel
MASTER_SITES= http://www.freedesktop.org/software/${PORTNAME}/

Expand Down
11 changes: 11 additions & 0 deletions sysutils/accountsservice/files/patch-src_util.c
@@ -0,0 +1,11 @@
--- src/util.c.orig 2019-04-23 15:16:09 UTC
+++ src/util.c
@@ -254,7 +254,7 @@ get_user_groups (const gchar *user,
*groups = g_new (gid_t, ngroups);
res = getgrouplist (user, group, *groups, &ngroups);

- return res;
+ return res == 0 ? ngroups : res;
}


0 comments on commit 2352c3f

Please sign in to comment.