diff options
author | Brian Harring <ferringb@gentoo.org> | 2005-07-28 18:54:15 +0000 |
---|---|---|
committer | Brian Harring <ferringb@gentoo.org> | 2005-07-28 18:54:15 +0000 |
commit | e45e21b6eda7a351723c9f21ee13eca736d7977e (patch) | |
tree | 2655e39f20201d83d632f35aacdbe76fc56b09a9 | |
parent | bug fixes, and updates. (diff) | |
download | portage-cvs-e45e21b6eda7a351723c9f21ee13eca736d7977e.tar.gz portage-cvs-e45e21b6eda7a351723c9f21ee13eca736d7977e.tar.bz2 portage-cvs-e45e21b6eda7a351723c9f21ee13eca736d7977e.zip |
bug in bool_parser's var interpretation ("no" != True, "no" == False)
-rw-r--r-- | portage/config/central.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/portage/config/central.py b/portage/config/central.py index 5db836c..f28f408 100644 --- a/portage/config/central.py +++ b/portage/config/central.py @@ -1,7 +1,7 @@ # Copyright: 2005 Gentoo Foundation # Author(s): Brian Harring (ferringb@gentoo.org) # License: GPL2 -# $Header: /local/data/ulm/cvs/history/var/cvsroot/gentoo-src/portage/portage/config/central.py,v 1.6 2005/07/21 19:50:17 ferringb Exp $ +# $Header: /local/data/ulm/cvs/history/var/cvsroot/gentoo-src/portage/portage/config/central.py,v 1.7 2005/07/28 18:54:15 ferringb Exp $ import errors, new from portage.const import CONF_DEFAULTS @@ -281,4 +281,7 @@ def str_parser(s): return '' def bool_parser(s): - return bool(str_parser(s)) + s = str_parser(s).lower() + if s in ("", "no", "false", "0"): + return False + return True |