summaryrefslogtreecommitdiff
path: root/hplip-systray-blockerror.patch
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2024-08-05 02:45:17 +0000
committerCoprDistGit <infra@openeuler.org>2024-08-05 02:45:17 +0000
commit92ff4cdf8c84e91584dd6076aa5b3c774ab0a622 (patch)
tree6ba01d84d85f00b380477077d920c341c3570b09 /hplip-systray-blockerror.patch
parentd8ce4006ffe8011c16c265205aa330c52a0de0c1 (diff)
automatic import of hplipopeneuler24.03_LTS
Diffstat (limited to 'hplip-systray-blockerror.patch')
-rw-r--r--hplip-systray-blockerror.patch20
1 files changed, 20 insertions, 0 deletions
diff --git a/hplip-systray-blockerror.patch b/hplip-systray-blockerror.patch
new file mode 100644
index 0000000..92a8cdf
--- /dev/null
+++ b/hplip-systray-blockerror.patch
@@ -0,0 +1,20 @@
+diff --git a/systray.py b/systray.py
+index 07db0fa..3a35b30 100644
+--- a/systray.py
++++ b/systray.py
+@@ -89,7 +89,14 @@ if __name__ == '__main__':
+ log.debug("Creating pipe: hpssd (%d) ==> systemtray (%d)" % (w1, r1))
+
+ parent_pid = os.getpid()
+- child_pid1 = os.fork()
++ try:
++ child_pid1 = os.fork()
++ except BlockingIOErrror as e:
++ log.error("hp-systray: error during fork - %s" % e)
++ os.close(w1)
++ os.close(r1)
++ mod.unlockInstance()
++ sys.exit(1)
+
+ if child_pid1:
+ # parent (UI)