View Issue Details

IDProjectCategoryView StatusLast Update
0001399Issue 8 draftsSystem Interfacespublic2020-09-17 08:31
Reportermkerrisk Assigned To 
PrioritynormalSeverityEditorialTypeError
Status ClosedResolutionWithdrawn 
Product VersionDraft 1 
NameMichael Kerrisk
Organizationman7.org
User Reference
Sectiongetgroups
Page Number1024
Line Number35217
Final Accepted Text
Summary0001399: Typo in variable name (nogroups ==> ngroups)
DescriptionIn the EXAMPLES section of getgroups(), there is the following:

[[
gid_t *group;
int nogroups;
long ngroups_max;
ngroups_max = sysconf(_SC_NGROUPS_MAX) + 1;
group = (gid_t *)malloc(ngroups_max *sizeof(gid_t));
ngroups = getgroups(ngroups_max, group);
]]

A variable called "nogroups" is declared, but later the variable used in line 35221 is called "ngroups". To fix this (in away that employs variable names that are also consistent with line 35218), "nogroups" should be changed to "ngroups".

Note that the same issue is present in Issue 7, 2018 Edition.
Desired ActionIn line 35217, change "nogroups" to "ngroups".
TagsNo tags attached.

Relationships

related to 0001400 Closed 1003.1(2016/18)/Issue7+TC2 Typo in variable name (nogroups ==> ngroups) 

Activities

Don Cragun

2020-09-17 06:28

manager   bugnote:0004994

Last edited: 2020-09-17 06:29

0001399 and 0001400 identify the same problem in two versions of the standard.

I believe that one of these bugs should be accepted with tags tc3-2008 and issue8 and the other one should be closed as a duplicate.

geoffclare

2020-09-17 08:01

manager   bugnote:0004995

Re: 0001399:0004994 Alternatively, Michael could ask to withdraw this bug, which we could then do straight away, and would save us having to process both bugs in a teleconference.

Just to be clear, the reason only one bug is needed here is not so much because it's the same problem but because the change needed to fix it is the same. In a case where the same problem would need different changes in TC3 and Issue 8, two bugs would be needed (unless the difference is simple enough to be covered in a "Note to the editor" in the editing instructions).

mkerrisk

2020-09-17 08:09

reporter   bugnote:0004996

Please withdraw this bug.

I was unsure of what the right process would be, since, although the fixes are the same, the line numbering is different. My apologies for creating the extra clutter.

Issue History

Date Modified Username Field Change
2020-09-17 06:04 mkerrisk New Issue
2020-09-17 06:04 mkerrisk Name => Michael Kerrisk
2020-09-17 06:04 mkerrisk Organization => man7.org
2020-09-17 06:04 mkerrisk Section => getgroups
2020-09-17 06:04 mkerrisk Page Number => 1024
2020-09-17 06:04 mkerrisk Line Number => 35217
2020-09-17 06:28 Don Cragun Note Added: 0004994
2020-09-17 06:29 Don Cragun Relationship added related to 0001400
2020-09-17 06:29 Don Cragun Note Edited: 0004994
2020-09-17 08:01 geoffclare Note Added: 0004995
2020-09-17 08:09 mkerrisk Note Added: 0004996
2020-09-17 08:31 geoffclare Status New => Closed
2020-09-17 08:31 geoffclare Resolution Open => Withdrawn