pthread_attr_setguardsize(3) Library Functions Manual pthread_attr_setguardsize, pthread_attr_getguardsize - / LIBRARY POSIX threads library (libpthread, -lpthread) #include int pthread_attr_setguardsize(pthread_attr_t *attr, size_t guardsize); int pthread_attr_getguardsize(const pthread_attr_t *restrict attr, size_t *restrict guardsize); pthread_attr_setguardsize() , attr, guardsize. guardsize 0, , attr, guardsize , ( ). guardsize 0, , attr, . . attr ( pthread_attr_setstack(3) pthread_attr_setstackaddr(3)), , , (. ., ): (, mprotect(2), ). pthread_attr_getguardsize() , attr, guardsize. 0; . POSIX.1 EINVAL attr guardsize. Linux ( , ). attributes(7). +-----------------------------+----------------------------------------------------------+--------------------------+ | | | | +-----------------------------+----------------------------------------------------------+--------------------------+ |pthread_attr_setguardsize(), | | MT-Safe | |pthread_attr_getguardsize() | | | +-----------------------------+----------------------------------------------------------+--------------------------+ POSIX.1-2008. glibc 2.1. POSIX.1-2001. , . , SIGSEGV . , ( , pthread_attr_getguardsize() , pthread_attr_setguardsize()). , , . . glibc 2.8 NPTL , POSIX.1 ( EINVAL pthread_create(3), ). LinuxThreads , . . pthread_getattr_np(3). . mmap(2), mprotect(2), pthread_attr_init(3), pthread_attr_setstack(3), pthread_attr_setstacksize(3), pthread_create(3), pthreads(7) Alexey, Azamat Hackimov , kogamatranslator49 , Kogan, Max Is , Yuri Kozlov ; GNU 3 , . . , , . Linux man-pages 6.06 31 2023 . pthread_attr_setguardsize(3)