]> xenbits.xensource.com Git - unikraft/libs/pthread-embedded.git/commitdiff
include/pthread.h: Guard C code for C++
authorTeodora Serbanescu <teo.serbanescu16@gmail.com>
Mon, 3 Jun 2019 15:16:40 +0000 (18:16 +0300)
committerFlorian Schmidt <florian.schmidt@neclab.eu>
Tue, 4 Jun 2019 13:41:32 +0000 (15:41 +0200)
Signed-off-by: Teodora Serbanescu <teo.serbanescu16@gmail.com>
Reviewed-by: Florian Schmidt <florian.schmidt@neclab.eu>
include/pthread.h

index 8cd1ade90efe69c6f7cfa6689dfbb22014ca589f..799f39b6bafb9f5d4f11f69c69308660a04e6dcf 100644 (file)
 #ifndef __GLUE_PTHREAD_H__
 #define __GLUE_PTHREAD_H__
 
-#include_next <pthread.h>
-
-/* C functions not implemented in pthread-embedded */
 #ifdef __cplusplus
 extern "C" {
 #endif
 
+/* The C code in pthread.h is not guarded for C++ */
+#include_next <pthread.h>
+
+/* C functions not implemented in pthread-embedded */
 int pthread_attr_setguardsize(pthread_attr_t *attr, size_t guardsize);
 int pthread_attr_getguardsize(const pthread_attr_t *attr, size_t *guardsize);