summaryrefslogtreecommitdiff
path: root/debian/patches/72_id_checkngroups.patch
blob: 15db91bc3bb00b65320f989fa6173ec4e452a9f3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#! /bin/sh /usr/share/dpatch/dpatch-run

@DPATCH@
Index: b/src/id.c
===================================================================
--- a/src/id.c
+++ b/src/id.c
@@ -416,6 +416,10 @@ print_full_info (const char *username)
         ok = false;
         return;
       }
+    else if (sysconf(_SC_NGROUPS_MAX) > 0 && n_groups > sysconf(_SC_NGROUPS_MAX))
+      {
+        fprintf (stderr, _("Warning: user %s is in more groups than system's configured maximum.\n"), (username != NULL)?username:"");
+      }
 
     if (n_groups > 0)
       fputs (_(" groups="), stdout);