diff options
author | Rich Felker <dalias@aerifal.cx> | 2018-10-16 13:48:10 -0400 |
---|---|---|
committer | Rich Felker <dalias@aerifal.cx> | 2018-10-16 14:10:27 -0400 |
commit | bf453d68393f7eea5965319e21311e56d71fa53c (patch) | |
tree | 3a71e0b3d8251b38863f71dbc634e3ed3dbba98d /include/pthread.h | |
parent | 1c84c99913bf1cd47b866ed31e665848a0da84a2 (diff) | |
download | musl-bf453d68393f7eea5965319e21311e56d71fa53c.tar.gz musl-bf453d68393f7eea5965319e21311e56d71fa53c.tar.xz musl-bf453d68393f7eea5965319e21311e56d71fa53c.zip |
restore attribute((const)) to pthread_self and errno location decls
revert commit a603a75a72bb469c6be4963ed1b55fabe675fe15. as a result of commit 1c84c99913bf1cd47b866ed31e665848a0da84a2 this is now safe, assuming an interpretation of the somewhat-underspecified attribute((const)) consistent with real-world usage.
Diffstat (limited to 'include/pthread.h')
-rw-r--r-- | include/pthread.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/pthread.h b/include/pthread.h index bba9587e..e238321b 100644 --- a/include/pthread.h +++ b/include/pthread.h @@ -79,6 +79,9 @@ int pthread_detach(pthread_t); _Noreturn void pthread_exit(void *); int pthread_join(pthread_t, void **); +#ifdef __GNUC__ +__attribute__((const)) +#endif pthread_t pthread_self(void); int pthread_equal(pthread_t, pthread_t); |