diff mbox series

[05/23] pthread_attr_setstack.3: SYNOPSIS: Use 'restrict' in prototypes

Message ID 20210308185331.242176-6-alx.manpages@gmail.com
State New
Headers show
Series man3: SYNOPSIS: Use 'restrict' in prototypes (batch 4) | expand

Commit Message

Alejandro Colomar March 8, 2021, 6:53 p.m. UTC
Both POSIX and glibc use 'restrict' in pthread_attr_setstack().
Let's use it here too.

.../glibc$ grep_glibc_prototype pthread_attr_setstack
sysdeps/htl/pthread.h:158:
extern int pthread_attr_setstack (pthread_attr_t *__attr,
				  void *__stackaddr,
				  size_t __stacksize)
	__THROW __nonnull ((1));
sysdeps/nptl/pthread.h:367:
extern int pthread_attr_setstack (pthread_attr_t *__attr, void *__stackaddr,
				  size_t __stacksize) __THROW __nonnull ((1));
.../glibc$

Signed-off-by: Alejandro Colomar <alx.manpages@gmail.com>
---
 man3/pthread_attr_setstack.3 | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/man3/pthread_attr_setstack.3 b/man3/pthread_attr_setstack.3
index 23b95cb32..6d0488a8b 100644
--- a/man3/pthread_attr_setstack.3
+++ b/man3/pthread_attr_setstack.3
@@ -33,8 +33,9 @@  attributes in thread attributes object
 .PP
 .BI "int pthread_attr_setstack(pthread_attr_t *" attr ,
 .BI "                          void *" stackaddr ", size_t " stacksize );
-.BI "int pthread_attr_getstack(const pthread_attr_t *" attr ,
-.BI "                          void **" stackaddr ", size_t *" stacksize );
+.BI "int pthread_attr_getstack(const pthread_attr_t *restrict " attr ,
+.BI "                          void **restrict " stackaddr ,
+.BI "                          size_t *restrict " stacksize );
 .PP
 Compile and link with \fI\-pthread\fP.
 .fi