]> git.dolda2000.com Git - ashd.git/commitdiff
python: Ignore EINTR in serveloop.
authorFredrik Tolf <fredrik@dolda2000.com>
Sat, 15 Jul 2023 14:03:38 +0000 (16:03 +0200)
committerFredrik Tolf <fredrik@dolda2000.com>
Sat, 15 Jul 2023 14:03:38 +0000 (16:03 +0200)
python3/ashd/util.py

index 3818e4b86b012f6847e2c26b45095cfc03021f1f..bf32637c83262f0740041e971ad8c2d78ceff675 100644 (file)
@@ -161,7 +161,10 @@ def serveloop(handler, sock = 0):
     and is called once for each received request.
     """
     while True:
-        req = proto.recvreq(sock)
+        try:
+            req = proto.recvreq(sock)
+        except InterruptedError:
+            continue
         if req is None:
             break
         try: