Catch curses.error instead of a non-existent global (PyChecker)
Edit comment
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 @@
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)