From 8b1922e6b8928524babc507552fe0bd4668a24e6 Mon Sep 17 00:00:00 2001 From: Todd Zullinger Date: Thu, 25 Jun 2009 14:18:27 -0400 Subject: [PATCH] gnome-post-receive-email: Encode user names as needed For user names that are ascii, this changes nothing. When user names contain non-ascii, the name will be encoded per RFC 2047. --- gnome-post-receive-email | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/gnome-post-receive-email b/gnome-post-receive-email index d1f7084..d4bf04d 100755 --- a/gnome-post-receive-email +++ b/gnome-post-receive-email @@ -33,6 +33,7 @@ import re import os import pwd import sys +from email import Header script_path = os.path.realpath(os.path.abspath(sys.argv[0])) script_dir = os.path.dirname(script_path) @@ -850,7 +851,7 @@ def main(): if m: fullname = m.group(1).strip() if fullname != "": - user_fullname = fullname + user_fullname = Header.Header(fullname, 'utf-8').encode() changes = [] -- 1.6.3.3