From: Alejandro Colomar Date: Thu, 25 Aug 2022 20:15:17 +0000 (+0200) Subject: confstr.3: Rename 'len' to 'size' X-Git-Tag: man-pages-6.00~131 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c92774db7ea2afd75d3574ae2f2fe50e0158ef22;p=thirdparty%2Fman-pages.git confstr.3: Rename 'len' to 'size' The parameter doesn't represent a string length (strlen(3)), but a buffer size (sizeof()). Use a more proper name. Signed-off-by: Alejandro Colomar --- diff --git a/man3/confstr.3 b/man3/confstr.3 index e6c463d967..5bc334c02a 100644 --- a/man3/confstr.3 +++ b/man3/confstr.3 @@ -20,7 +20,7 @@ Standard C library .nf .B #include .PP -.BI "size_t confstr(int " "name" ", char *" buf ", size_t " len ); +.BI "size_t confstr(int " "name" ", char *" buf ", size_t " size ); .fi .PP .RS -4 @@ -58,21 +58,21 @@ be found. If .I buf is not NULL and -.I len +.I size is not zero, .BR confstr () copies the value of the string to .I buf truncated to -.I len \- 1 +.I size \- 1 bytes if necessary, with a null byte (\(aq\e0\(aq) as terminator. This can be detected by comparing the return value of .BR confstr () against -.IR len . +.IR size . .PP If -.I len +.I size is zero and .I buf is NULL, @@ -86,7 +86,7 @@ is a valid configuration variable, returns the number of bytes (including the terminating null byte) that would be required to hold the entire value of that variable. This value may be greater than -.IR len , +.IR size , which means that the value in .I buf is truncated.