Address issue #1049046.

* lib/viewcvs.py
  (_re_rewrite_email): Allow plus signs in email addresses.


git-svn-id: http://viewvc.tigris.org/svn/viewvc/trunk@959 8cb11bc2-c004-0410-86c3-e597b4017df7
remotes/tags/1.0.0-rc1
cmpilato 2004-10-18 16:03:44 +00:00
parent 68ebc10d44
commit 4884f8f5c6
1 changed files with 1 additions and 1 deletions

View File

@ -735,7 +735,7 @@ def is_plain_text(mime_type):
return not mime_type or mime_type == 'text/plain'
_re_rewrite_url = re.compile('((http|https|ftp|file|svn|svn\+ssh)(://[-a-zA-Z0-9%.~:_/]+)([?&]([-a-zA-Z0-9%.~:_]+)=([-a-zA-Z0-9%.~:_])+)*(#([-a-zA-Z0-9%.~:_]+)?)?)')
_re_rewrite_email = re.compile('([-a-zA-Z0-9_.]+)@(([-a-zA-Z0-9]+\.)+[A-Za-z]{2,4})')
_re_rewrite_email = re.compile('([-a-zA-Z0-9_.\+]+)@(([-a-zA-Z0-9]+\.)+[A-Za-z]{2,4})')
def htmlify(html):
html = cgi.escape(html)
html = re.sub(_re_rewrite_url, r'<a href="\1">\1</a>', html)