Accept 0 and negative value for count
We already accept zero and negative value with the option -n, for consistency it is good to accept it in interactive mode.
This commit is contained in:
parent
54a16964d4
commit
a5a4c2e44a
1 changed files with 2 additions and 2 deletions
|
|
@ -832,8 +832,8 @@ class ReplApplication(Cmd, ConsoleApplication):
|
||||||
self.options.count = count
|
self.options.count = count
|
||||||
self._is_default_count = False
|
self._is_default_count = False
|
||||||
else:
|
else:
|
||||||
print >>sys.stderr, 'Number must be at least 1.'
|
self.options.count = None
|
||||||
return 2
|
self._is_default_count = False
|
||||||
else:
|
else:
|
||||||
if self.options.count is None:
|
if self.options.count is None:
|
||||||
print 'Counting disabled.'
|
print 'Counting disabled.'
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue