diff options
author | Andrew M. Kuchling <amk@amk.ca> | 2001-08-13 13:47:23 (GMT) |
---|---|---|
committer | Andrew M. Kuchling <amk@amk.ca> | 2001-08-13 13:47:23 (GMT) |
commit | fee3126eb35a520f62de71bd038841ae51ba5ad4 (patch) | |
tree | 1c2209244154bf7274dc5a2e33fa85ad8b13270b /Lib/curses | |
parent | 40ea6177b975432804cd94608a2584d29adf45b5 (diff) | |
download | cpython-fee3126eb35a520f62de71bd038841ae51ba5ad4.zip cpython-fee3126eb35a520f62de71bd038841ae51ba5ad4.tar.gz cpython-fee3126eb35a520f62de71bd038841ae51ba5ad4.tar.bz2 |
Catch curses.error instead of a non-existent global (PyChecker)
Edit comment
Diffstat (limited to 'Lib/curses')
-rw-r--r-- | Lib/curses/textpad.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/curses/textpad.py b/Lib/curses/textpad.py index e0e3d8b..2b03648 100644 --- a/Lib/curses/textpad.py +++ b/Lib/curses/textpad.py @@ -66,10 +66,10 @@ class Textbox: if y < self.maxy or x < self.maxx: # The try-catch ignores the error we trigger from some curses # versions by trying to write into the lowest-rightmost spot - # in the self.window. + # in the window. try: self.win.addch(ch) - except ERR: + except curses.error: pass elif ch == ascii.SOH: # ^a self.win.move(y, 0) |