summaryrefslogtreecommitdiffstats
path: root/Lib/distutils/log.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2003-02-20 02:09:30 (GMT)
committerGuido van Rossum <guido@python.org>2003-02-20 02:09:30 (GMT)
commita85dbeb61fe9357b15b4f987d9bc62f67e77b55f (patch)
tree92a3950a8ba9c2fff5a69a1afbd32b42d78e0c1d /Lib/distutils/log.py
parent351a7dd64abd42ebfc0e11afe8996d3934ee18e3 (diff)
downloadcpython-a85dbeb61fe9357b15b4f987d9bc62f67e77b55f.zip
cpython-a85dbeb61fe9357b15b4f987d9bc62f67e77b55f.tar.gz
cpython-a85dbeb61fe9357b15b4f987d9bc62f67e77b55f.tar.bz2
set_verbosity(): do something reasonable for out-of-range verbosity
levels. (Previously, -vvv would be the same as -q!)
Diffstat (limited to 'Lib/distutils/log.py')
-rw-r--r--Lib/distutils/log.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/Lib/distutils/log.py b/Lib/distutils/log.py
index 0442033..01420da 100644
--- a/Lib/distutils/log.py
+++ b/Lib/distutils/log.py
@@ -53,9 +53,9 @@ def set_threshold(level):
_global_log.threshold = level
def set_verbosity(v):
- if v == 0:
+ if v <= 0:
set_threshold(WARN)
- if v == 1:
+ elif v == 1:
set_threshold(INFO)
- if v == 2:
+ elif v >= 2:
set_threshold(DEBUG)