From 6571c260b972da7d3109d61ef34aee3f984c9c0a Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Sun, 20 Jan 2013 08:34:13 -0500 Subject: [PATCH] Adapt to Unicode sys.argv --- mutt-ldap.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mutt-ldap.py b/mutt-ldap.py index d0f674a..03f8df9 100755 --- a/mutt-ldap.py +++ b/mutt-ldap.py @@ -177,10 +177,10 @@ if __name__ == '__main__': sys.argv = [unicode(arg, argv_encoding) for arg in sys.argv] if len(sys.argv) < 2: - sys.stderr.write('{0}: no search string given\n'.format(sys.argv[0])) + sys.stderr.write(u'{0}: no search string given\n'.format(sys.argv[0])) sys.exit(1) - query = unicode(' '.join(sys.argv[1:]), 'utf-8') + query = u' '.join(sys.argv[1:]) (cache_hit, addresses) = cache_lookup(query) -- 2.26.2