diff options
| author | Andrew M. Kuchling <amk@amk.ca> | 2001-08-13 13:47:23 +0000 |
|---|---|---|
| committer | Andrew M. Kuchling <amk@amk.ca> | 2001-08-13 13:47:23 +0000 |
| commit | f4860629ab36602706190119a68634491930dec5 (patch) | |
| tree | ce59123623b7cbbc126277031c65be0c4efbd218 /Lib/curses | |
| parent | 0eff31b8627fd50f51e7d8d82c3b092a7ecc9ebd (diff) | |
| download | cpython-f4860629ab36602706190119a68634491930dec5.tar.gz | |
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 e0e3d8bdce..2b03648628 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) |
