提交 9fc0adfc 编写于 作者: S Stefan Raspl 提交者: Paolo Bonzini

tools/kvm_stat: catch curses exceptions only

The previous version was catching all exceptions, including SIGINT.
We only want to catch the curses exceptions here.
Signed-off-by: NStefan Raspl <raspl@linux.vnet.ibm.com>
Reviewed-by: NJanosch Frank <frankja@linux.vnet.ibm.com>
Reviewed-by: NSascha Silbe <silbe@linux.vnet.ibm.com>
Reviewed-by: NMarc Hartmayer <mhartmay@linux.vnet.ibm.com>
Signed-off-by: NRadim Krčmář <rkrcmar@redhat.com>
上级 a0b4e6a0
......@@ -809,7 +809,7 @@ class Tui(object):
# return from C start_color() is ignorable.
try:
curses.start_color()
except:
except curses.error:
pass
# Hide cursor in extra statement as some monochrome terminals
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册