-rw-r--r-- | noncore/applets/keyhelper/keyhelperapplet/anylnk/ProcessInvoker.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/noncore/applets/keyhelper/keyhelperapplet/anylnk/ProcessInvoker.cpp b/noncore/applets/keyhelper/keyhelperapplet/anylnk/ProcessInvoker.cpp index 09605bd..ff06551 100644 --- a/noncore/applets/keyhelper/keyhelperapplet/anylnk/ProcessInvoker.cpp +++ b/noncore/applets/keyhelper/keyhelperapplet/anylnk/ProcessInvoker.cpp | |||
@@ -1,26 +1,30 @@ | |||
1 | #include "ProcessInvoker.h" | 1 | #include "ProcessInvoker.h" |
2 | 2 | ||
3 | #ifndef PIPE_BUF // uClibc or similar | ||
4 | #include <linux/limits.h> | ||
5 | #endif | ||
6 | |||
3 | static ProcessInvoker* g_this; | 7 | static ProcessInvoker* g_this; |
4 | /* ------------------------------------------------------------------------ */ | 8 | /* ------------------------------------------------------------------------ */ |
5 | /* static functions */ | 9 | /* static functions */ |
6 | /* ------------------------------------------------------------------------ */ | 10 | /* ------------------------------------------------------------------------ */ |
7 | 11 | ||
8 | static Sigfunc* setSignalHandler(int signo, Sigfunc* handler) | 12 | static Sigfunc* setSignalHandler(int signo, Sigfunc* handler) |
9 | { | 13 | { |
10 | struct sigaction act,oact; | 14 | struct sigaction act,oact; |
11 | 15 | ||
12 | act.sa_handler = handler; | 16 | act.sa_handler = handler; |
13 | ::sigemptyset(&act.sa_mask); | 17 | ::sigemptyset(&act.sa_mask); |
14 | act.sa_flags = 0; | 18 | act.sa_flags = 0; |
15 | #ifdefSA_RESTART | 19 | #ifdefSA_RESTART |
16 | act.sa_flags |= SA_RESTART; | 20 | act.sa_flags |= SA_RESTART; |
17 | #endif | 21 | #endif |
18 | if(::sigaction(signo, &act, &oact) < 0){ | 22 | if(::sigaction(signo, &act, &oact) < 0){ |
19 | return(NULL); | 23 | return(NULL); |
20 | } | 24 | } |
21 | return(oact.sa_handler); | 25 | return(oact.sa_handler); |
22 | } | 26 | } |
23 | 27 | ||
24 | static void childHandler(int /*signo*/) | 28 | static void childHandler(int /*signo*/) |
25 | { | 29 | { |
26 | pid_t pid; | 30 | pid_t pid; |