diff options
author | Alejandro Colomar <alx.manpages@gmail.com> | 2022-08-25 22:15:17 +0200 |
---|---|---|
committer | Alejandro Colomar <alx.manpages@gmail.com> | 2022-08-25 22:15:18 +0200 |
commit | c92774db7ea2afd75d3574ae2f2fe50e0158ef22 (patch) | |
tree | ad6d24df25967b6321d83ca0cd25240320b378f4 | |
parent | e5da16f10f2d3d55db0bb1ef1156afcb197d8fdc (diff) |
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 <alx.manpages@gmail.com>
-rw-r--r-- | man3/confstr.3 | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/man3/confstr.3 b/man3/confstr.3 index e6c463d96..5bc334c02 100644 --- a/man3/confstr.3 +++ b/man3/confstr.3 @@ -20,7 +20,7 @@ Standard C library .nf .B #include <unistd.h> .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. |