Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6353165 commit 444838eCopy full SHA for 444838e
lib/matplotlib/backends/backend_qt5.py
@@ -1042,9 +1042,11 @@ def trigger_manager_draw(manager):
1042
def mainloop():
1043
old_signal = signal.getsignal(signal.SIGINT)
1044
# allow SIGINT exceptions to close the plot window.
1045
- signal.signal(signal.SIGINT, signal.SIG_DFL)
+ if old_signal:
1046
+ signal.signal(signal.SIGINT, signal.SIG_DFL)
1047
try:
1048
qApp.exec_()
1049
finally:
1050
# reset the SIGINT exception handler
- signal.signal(signal.SIGINT, old_signal)
1051
1052
+ signal.signal(signal.SIGINT, old_signal)
0 commit comments