From 103d6e7a3c9feed2ef54d51c77f0daa614dc936a Mon Sep 17 00:00:00 2001 From: =?utf8?q?Martin=20v=2E=20L=C3=B6wis?= Date: Sun, 30 Mar 2003 15:42:13 +0000 Subject: [PATCH] Support '' as the argument for the setlocale emulation. Fixes #678259. --- Lib/locale.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/locale.py b/Lib/locale.py index 3551261469..2028948e9b 100644 --- a/Lib/locale.py +++ b/Lib/locale.py @@ -69,7 +69,7 @@ except ImportError: """ setlocale(integer,string=None) -> string. Activates/queries locale processing. """ - if value is not None and value != 'C': + if value not in (None, '', 'C'): raise Error, '_locale emulation only supports "C" locale' return 'C' -- 2.50.1