packages/net/nfs-utils/patches/001-no-getgrouplist.patch

34 lines
999 B
Diff
Raw Normal View History

Index: nfs-utils-1.1.2/utils/mountd/cache.c
===================================================================
--- nfs-utils-1.1.2.orig/utils/mountd/cache.c 2008-04-13 10:38:24.000000000 +0200
+++ nfs-utils-1.1.2/utils/mountd/cache.c 2008-04-13 10:38:25.000000000 +0200
@@ -141,17 +141,17 @@
pw = getpwuid(uid);
if (!pw)
rv = -1;
- else {
- rv = getgrouplist(pw->pw_name, pw->pw_gid, groups, &ngroups);
- if (rv == -1 && ngroups >= 100) {
- groups = malloc(sizeof(gid_t)*ngroups);
- if (!groups)
- rv = -1;
- else
- rv = getgrouplist(pw->pw_name, pw->pw_gid,
- groups, &ngroups);
- }
- }
+// else {
+// rv = getgrouplist(pw->pw_name, pw->pw_gid, groups, &ngroups);
+// if (rv == -1 && ngroups >= 100) {
+// groups = malloc(sizeof(gid_t)*ngroups);
+// if (!groups)
+// rv = -1;
+// else
+// rv = getgrouplist(pw->pw_name, pw->pw_gid,
+// groups, &ngroups);
+// }
+// }
qword_printint(f, uid);
qword_printint(f, time(0)+30*60);
if (rv >= 0) {