提交 9505bfbc 编写于 作者: R Rich Felker

fix signal.h breakage from moving stack_t to arch-specific bits

in the previous changes, I missed the fact that both the prototype of
the sigaltstack function and the definition of ucontext_t depend on
stack_t.
上级 12f37cde
...@@ -18,6 +18,12 @@ typedef struct { ...@@ -18,6 +18,12 @@ typedef struct {
} mcontext_t; } mcontext_t;
#endif #endif
struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
};
typedef struct __ucontext { typedef struct __ucontext {
unsigned long uc_flags; unsigned long uc_flags;
struct __ucontext *uc_link; struct __ucontext *uc_link;
...@@ -27,12 +33,6 @@ typedef struct __ucontext { ...@@ -27,12 +33,6 @@ typedef struct __ucontext {
unsigned long long uc_regspace[64]; unsigned long long uc_regspace[64];
} ucontext_t; } ucontext_t;
typedef struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
} stack_t;
#define SA_NOCLDSTOP 1 #define SA_NOCLDSTOP 1
#define SA_NOCLDWAIT 2 #define SA_NOCLDWAIT 2
#define SA_SIGINFO 4 #define SA_SIGINFO 4
......
...@@ -53,6 +53,12 @@ typedef struct { ...@@ -53,6 +53,12 @@ typedef struct {
} mcontext_t; } mcontext_t;
#endif #endif
struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
};
typedef struct __ucontext { typedef struct __ucontext {
unsigned long uc_flags; unsigned long uc_flags;
struct __ucontext *uc_link; struct __ucontext *uc_link;
...@@ -62,12 +68,6 @@ typedef struct __ucontext { ...@@ -62,12 +68,6 @@ typedef struct __ucontext {
unsigned long __fpregs_mem[28]; unsigned long __fpregs_mem[28];
} ucontext_t; } ucontext_t;
typedef struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
} stack_t;
#define SA_NOCLDSTOP 1 #define SA_NOCLDSTOP 1
#define SA_NOCLDWAIT 2 #define SA_NOCLDWAIT 2
#define SA_SIGINFO 4 #define SA_SIGINFO 4
......
...@@ -21,6 +21,12 @@ typedef struct { ...@@ -21,6 +21,12 @@ typedef struct {
} mcontext_t; } mcontext_t;
#endif #endif
struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
};
typedef struct __ucontext { typedef struct __ucontext {
unsigned long uc_flags; unsigned long uc_flags;
struct __ucontext *uc_link; struct __ucontext *uc_link;
...@@ -29,12 +35,6 @@ typedef struct __ucontext { ...@@ -29,12 +35,6 @@ typedef struct __ucontext {
sigset_t uc_sigmask; sigset_t uc_sigmask;
} ucontext_t; } ucontext_t;
typedef struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
} stack_t;
#define SA_NOCLDSTOP 1 #define SA_NOCLDSTOP 1
#define SA_NOCLDWAIT 2 #define SA_NOCLDWAIT 2
#define SA_SIGINFO 4 #define SA_SIGINFO 4
......
...@@ -38,6 +38,12 @@ typedef struct { ...@@ -38,6 +38,12 @@ typedef struct {
} mcontext_t; } mcontext_t;
#endif #endif
struct sigaltstack {
void *ss_sp;
size_t ss_size;
int ss_flags;
};
typedef struct __ucontext { typedef struct __ucontext {
unsigned long uc_flags; unsigned long uc_flags;
struct __ucontext *uc_link; struct __ucontext *uc_link;
...@@ -46,12 +52,6 @@ typedef struct __ucontext { ...@@ -46,12 +52,6 @@ typedef struct __ucontext {
sigset_t uc_sigmask; sigset_t uc_sigmask;
} ucontext_t; } ucontext_t;
typedef struct sigaltstack {
void *ss_sp;
size_t ss_size;
int ss_flags;
} stack_t;
#define SA_NOCLDSTOP 1 #define SA_NOCLDSTOP 1
#define SA_NOCLDWAIT 0x10000 #define SA_NOCLDWAIT 0x10000
#define SA_SIGINFO 8 #define SA_SIGINFO 8
......
...@@ -49,6 +49,12 @@ typedef struct { ...@@ -49,6 +49,12 @@ typedef struct {
#endif #endif
struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
};
typedef struct __ucontext { typedef struct __ucontext {
unsigned long uc_flags; unsigned long uc_flags;
struct __ucontext *uc_link; struct __ucontext *uc_link;
...@@ -60,12 +66,6 @@ typedef struct __ucontext { ...@@ -60,12 +66,6 @@ typedef struct __ucontext {
mcontext_t uc_mcontext; mcontext_t uc_mcontext;
} ucontext_t; } ucontext_t;
typedef struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
} stack_t;
#define SA_NOCLDSTOP 1U #define SA_NOCLDSTOP 1U
#define SA_NOCLDWAIT 2U #define SA_NOCLDWAIT 2U
#define SA_SIGINFO 4U #define SA_SIGINFO 4U
......
...@@ -19,6 +19,12 @@ typedef struct { ...@@ -19,6 +19,12 @@ typedef struct {
} mcontext_t; } mcontext_t;
#endif #endif
struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
};
typedef struct __ucontext { typedef struct __ucontext {
unsigned long uc_flags; unsigned long uc_flags;
struct __ucontext *uc_link; struct __ucontext *uc_link;
...@@ -27,12 +33,6 @@ typedef struct __ucontext { ...@@ -27,12 +33,6 @@ typedef struct __ucontext {
sigset_t uc_sigmask; sigset_t uc_sigmask;
} ucontext_t; } ucontext_t;
typedef struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
} stack_t;
#define SA_NOCLDSTOP 1 #define SA_NOCLDSTOP 1
#define SA_NOCLDWAIT 2 #define SA_NOCLDWAIT 2
#define SA_SIGINFO 4 #define SA_SIGINFO 4
......
...@@ -60,6 +60,12 @@ typedef struct { ...@@ -60,6 +60,12 @@ typedef struct {
} mcontext_t; } mcontext_t;
#endif #endif
struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
};
typedef struct __ucontext { typedef struct __ucontext {
unsigned long uc_flags; unsigned long uc_flags;
struct __ucontext *uc_link; struct __ucontext *uc_link;
...@@ -69,12 +75,6 @@ typedef struct __ucontext { ...@@ -69,12 +75,6 @@ typedef struct __ucontext {
unsigned long long __fpregs_mem[64]; unsigned long long __fpregs_mem[64];
} ucontext_t; } ucontext_t;
typedef struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
} stack_t;
#define SA_NOCLDSTOP 1 #define SA_NOCLDSTOP 1
#define SA_NOCLDWAIT 2 #define SA_NOCLDWAIT 2
#define SA_SIGINFO 4 #define SA_SIGINFO 4
......
...@@ -60,6 +60,12 @@ typedef struct { ...@@ -60,6 +60,12 @@ typedef struct {
} mcontext_t; } mcontext_t;
#endif #endif
struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
};
typedef struct __ucontext { typedef struct __ucontext {
unsigned long uc_flags; unsigned long uc_flags;
struct __ucontext *uc_link; struct __ucontext *uc_link;
...@@ -69,12 +75,6 @@ typedef struct __ucontext { ...@@ -69,12 +75,6 @@ typedef struct __ucontext {
unsigned long __fpregs_mem[64]; unsigned long __fpregs_mem[64];
} ucontext_t; } ucontext_t;
typedef struct sigaltstack {
void *ss_sp;
int ss_flags;
size_t ss_size;
} stack_t;
#define SA_NOCLDSTOP 1 #define SA_NOCLDSTOP 1
#define SA_NOCLDWAIT 2 #define SA_NOCLDWAIT 2
#define SA_SIGINFO 4 #define SA_SIGINFO 4
......
...@@ -77,6 +77,8 @@ extern "C" { ...@@ -77,6 +77,8 @@ extern "C" {
#define CLD_STOPPED 5 #define CLD_STOPPED 5
#define CLD_CONTINUED 6 #define CLD_CONTINUED 6
typedef struct sigaltstack stack_t;
union sigval { union sigval {
int sival_int; int sival_int;
void *sival_ptr; void *sival_ptr;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册