summaryrefslogtreecommitdiff
path: root/file.c
diff options
context:
space:
mode:
authorkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-02-21 04:41:39 +0000
committerkosaki <kosaki@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-02-21 04:41:39 +0000
commite93a68abfa10a7eba1fd769b6cbc55da7796f8e8 (patch)
treed916b38e05a345a02527b88a78b453bfc69e3530 /file.c
parent1cda6e3968b7245b302b20898ac02db3a6289309 (diff)
* file.c (RB_MAX_GROUPS): moved to
* internal.h (RB_MAX_GROUPS): here. * file.c (rb_group_member): use RB_MAX_GROUPS instead of RUBY_GROUP_MAX. They are the same. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@39352 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'file.c')
-rw-r--r--file.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/file.c b/file.c
index 819224e856..1cc7f63d18 100644
--- a/file.c
+++ b/file.c
@@ -1013,9 +1013,6 @@ rb_file_lstat(VALUE obj)
#endif
}
-/* Linux allow 65536 groups and it is maximum value as far as we know. */
-#define RUBY_GROUP_MAX 65536
-
static int
rb_group_member(GETGROUPS_T gid)
{
@@ -1036,7 +1033,7 @@ rb_group_member(GETGROUPS_T gid)
* accept more larger value.
* So we don't trunk NGROUPS anymore.
*/
- while (groups <= RUBY_GROUP_MAX) {
+ while (groups <= RB_MAX_GROUPS) {
gary = ALLOCV_N(GETGROUPS_T, v, groups);
anum = getgroups(groups, gary);
if (anum != groups)