From f9f94ca577aae5999a9a1c80b591e891bcf00935 Mon Sep 17 00:00:00 2001 From: ed Date: Thu, 19 Jun 2008 07:30:32 +0000 Subject: Remove __restrict keywords from array arguments to make GCC's -std=c99 work. When GCC is invoked with -std=c99, the following errors are displayed when including : /usr/include/spawn.h:69: error: static or type qualifiers in abstract declarator /usr/include/spawn.h:69: error: static or type qualifiers in abstract declarator /usr/include/spawn.h:72: error: static or type qualifiers in abstract declarator /usr/include/spawn.h:72: error: static or type qualifiers in abstract declarator We'd better remove the __restrict keywords here. The same is also done in . Submitted by: Andrzej Tobola Reviewed by: davidxu Approved by: philip (mentor, implicit) --- include/spawn.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'include/spawn.h') diff --git a/include/spawn.h b/include/spawn.h index 088b7c5..7889d0e 100644 --- a/include/spawn.h +++ b/include/spawn.h @@ -63,13 +63,16 @@ typedef struct __posix_spawn_file_actions *posix_spawn_file_actions_t; __BEGIN_DECLS /* * Spawn routines + * + * XXX both arrays should be __restrict, but this does not work when GCC + * is invoked with -std=c99. */ int posix_spawn(pid_t * __restrict, const char * __restrict, const posix_spawn_file_actions_t *, const posix_spawnattr_t * __restrict, - char * const [__restrict], char * const [__restrict]); + char * const [], char * const []); int posix_spawnp(pid_t * __restrict, const char * __restrict, const posix_spawn_file_actions_t *, const posix_spawnattr_t * __restrict, - char * const [__restrict], char * const [__restrict]); + char * const [], char * const []); /* * File descriptor actions -- cgit v1.1