forked from enlightenment/efl
ecore signal write - save and restore errno since may be on mainloop
now i disabled the signal thread watcher ... save+restore errno.
This commit is contained in:
parent
21c8e73111
commit
af681a1091
|
@ -11,6 +11,7 @@
|
|||
#include <unistd.h>
|
||||
#include <assert.h>
|
||||
#include <fcntl.h>
|
||||
#include <errno.h>
|
||||
#include <pthread.h>
|
||||
|
||||
#include "Ecore.h"
|
||||
|
@ -155,7 +156,12 @@ _ecore_signal_callback(int sig, siginfo_t *si, void *foo EINA_UNUSED)
|
|||
#endif
|
||||
sdata.sig = sig;
|
||||
sdata.info = *si;
|
||||
if (sdata.sig >= 0) write(sig_pipe[1], &sdata, sizeof(sdata));
|
||||
if (sdata.sig >= 0)
|
||||
{
|
||||
int err = errno;
|
||||
write(sig_pipe[1], &sdata, sizeof(sdata));
|
||||
errno = err;
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
Loading…
Reference in New Issue