Messages in this thread | | | From | Walter Harms <> | Subject | AW: AW: [PATCH 12/24] getgrent_r.3: Use sizeof() to get buffer size (instead of hardcoding macro name) | Date | Mon, 14 Sep 2020 09:24:20 +0000 |
| |
missunderstanding, i do not want to discuss sizeof() vs define
in this example you do: #define BUFLEN 4096 char buf[BUFLEN]; getgrent_r(&grp, buf, sizeof(buf), &grpp);
so there is no real need for BUFLEN anymore so donig char buf[BUFLEN]; -> char buf[4096]; would remove BUFLEN
________________________________________ Von: Alejandro Colomar [colomar.6.4.3@gmail.com] Gesendet: Freitag, 11. September 2020 21:17 An: Walter Harms; mtk.manpages@gmail.com Cc: linux-man@vger.kernel.org; linux-kernel@vger.kernel.org Betreff: Re: AW: [PATCH 12/24] getgrent_r.3: Use sizeof() to get buffer size (instead of hardcoding macro name)
Hi Walter,
On 2020-09-11 14:50, Walter Harms wrote: > BUFLEN should be remove completely or stay > > jm2c > wh
Sorry that you weren't CC'd in the conversation we are having about it. You can have a look at it here:
https://lore.kernel.org/linux-man/ab12151d-6951-2a36-2fc6-ea7eed538c45@gmail.com/T/#m423de347de6a64d099887d4ce615660d16d5b0e6
I'll CC you in the next reply there.
Cheers,
Alex
| |