diff options
author | Georg Brandl <georg@python.org> | 2013-10-14 16:08:15 +0200 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2013-10-14 16:08:15 +0200 |
commit | 1693c3595b4ea9f3653ed925c35263418847583c (patch) | |
tree | ceb56f493d05a193a13bcd5461ede50533437b94 | |
parent | 556a0314b7df6c70e0633c90c15c968d328ce498 (diff) | |
download | cpython-1693c3595b4ea9f3653ed925c35263418847583c.tar.gz |
Closes #17154: error out gracefully on "ignore" or "condition" without argument.
-rwxr-xr-x | Lib/pdb.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/pdb.py b/Lib/pdb.py index b4a19e4131..80cba9d36c 100755 --- a/Lib/pdb.py +++ b/Lib/pdb.py @@ -805,6 +805,8 @@ class Pdb(bdb.Bdb, cmd.Cmd): cond = None try: bp = self.get_bpbynumber(args[0].strip()) + except IndexError: + self.error('Breakpoint number expected') except ValueError as err: self.error(err) else: @@ -832,6 +834,8 @@ class Pdb(bdb.Bdb, cmd.Cmd): count = 0 try: bp = self.get_bpbynumber(args[0].strip()) + except IndexError: + self.error('Breakpoint number expected') except ValueError as err: self.error(err) else: |