summaryrefslogtreecommitdiff
path: root/ev.c
diff options
context:
space:
mode:
Diffstat (limited to 'ev.c')
-rw-r--r--ev.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/ev.c b/ev.c
index 7bed969..20d0e3b 100644
--- a/ev.c
+++ b/ev.c
@@ -415,8 +415,10 @@ sighandler (int signum)
if (!gotsig)
{
+ int old_errno = errno;
gotsig = 1;
write (sigpipe [1], &signum, 1);
+ errno = old_errno;
}
}