projects
/
platform
/
upstream
/
pulseaudio.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
44d7c9a
)
save and restore errno in sig handler
author
Lennart Poettering
<lennart@poettering.net>
Thu, 1 Nov 2007 01:42:34 +0000
(
01:42
+0000)
committer
Lennart Poettering
<lennart@poettering.net>
Thu, 1 Nov 2007 01:42:34 +0000
(
01:42
+0000)
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@2011
fefdeb5f
-60dc-0310-8127-
8f9354f1896f
src/daemon/cpulimit.c
patch
|
blob
|
history
diff --git
a/src/daemon/cpulimit.c
b/src/daemon/cpulimit.c
index
ab21212
..
b77dd44
100644
(file)
--- a/
src/daemon/cpulimit.c
+++ b/
src/daemon/cpulimit.c
@@
-113,6
+113,9
@@
static void write_err(const char *p) {
/* The signal handler, called on every SIGXCPU */
static void signal_handler(int sig) {
+ int saved_errno;
+
+ saved_errno = errno;
pa_assert(sig == SIGXCPU);
if (phase == PHASE_IDLE) {
@@
-150,6
+153,8
@@
static void signal_handler(int sig) {
write_err("Hard CPU time limit exhausted, terminating forcibly.\n");
_exit(1); /* Forced exit */
}
+
+ errno = saved_errno;
}
/* Callback for IO events on the FIFO */