aboutsummaryrefslogtreecommitdiffstats
path: root/man/man2/memfd_create.2
diff options
context:
space:
mode:
authorAlejandro Colomar <alx@kernel.org>2024-11-17 18:47:53 +0100
committerAlejandro Colomar <alx@kernel.org>2024-11-17 21:51:23 +0100
commit18e7c4597c4e72fa5210c7887273e363c456c9ee (patch)
tree97cfd22e731a4c859ae71783d70943ff72e6cb60 /man/man2/memfd_create.2
parent8fc6fdd8291d906e58a175b5e1b20da680aaeb4a (diff)
downloadman-pages-18e7c4597c4e.tar.gz
man/: Terminology consistency reforms (n, size, length)
Use 'length' for the lenght of a string. Use 'n' for the number of elements. Use 'size' for the number of bytes. (And in wide-character string functions, 'size' also refers to the number of wide characters.) The change is quite large, and I might have made some mistakes. But overall, this should improve consistency in use of these terms. Signed-off-by: Alejandro Colomar <alx@kernel.org>
Diffstat (limited to 'man/man2/memfd_create.2')
-rw-r--r--man/man2/memfd_create.26
1 files changed, 3 insertions, 3 deletions
diff --git a/man/man2/memfd_create.2 b/man/man2/memfd_create.2
index 33e3a04318..946890e660 100644
--- a/man/man2/memfd_create.2
+++ b/man/man2/memfd_create.2
@@ -425,7 +425,7 @@ main(int argc, char *argv[])
{
int fd;
char *name, *seals_arg;
- ssize_t len;
+ ssize_t size;
unsigned int seals;
\&
if (argc < 3) {
@@ -441,7 +441,7 @@ main(int argc, char *argv[])
}
\&
name = argv[1];
- len = atoi(argv[2]);
+ size = atoi(argv[2]);
seals_arg = argv[3];
\&
/* Create an anonymous file in tmpfs; allow seals to be
@@ -453,7 +453,7 @@ main(int argc, char *argv[])
\&
/* Size the file as specified on the command line. */
\&
- if (ftruncate(fd, len) == \-1)
+ if (ftruncate(fd, size) == \-1)
err(EXIT_FAILURE, "truncate");
\&
printf("PID: %jd; fd: %d; /proc/%jd/fd/%d\[rs]n",