]> code.delx.au - pulseaudio/blobdiff - src/modules/gconf/module-gconf.c
deal properly with signals interrupting us when we wait for data from gconf helper
[pulseaudio] / src / modules / gconf / module-gconf.c
index 1c8866de2bd7cdb67b5a202644b7a7ab7563c14c..c2ea7b27f5a1440fdb6fa637ce2117e93a57cc82 100644 (file)
@@ -225,8 +225,11 @@ static int handle_event(struct userdata *u) {
     int ret = 0;
 
     do {
-        if ((opcode = read_byte(u)) < 0)
+        if ((opcode = read_byte(u)) < 0){
+            if (errno == EINTR || errno == EAGAIN)
+                break;
             goto fail;
+        }
 
         switch (opcode) {
             case '!':
@@ -509,4 +512,3 @@ void pa__done(pa_module*m) {
 
     pa_xfree(u);
 }
-