util: fix unsafe url abort with bytestr() on url
authorAugie Fackler <augie@google.com>
Sun, 04 Mar 2018 15:55:55 -0500
changeset 36724 ca201470abb4
parent 36723 1f9bbd1d6b8a
child 36725 93b8c83ef136
util: fix unsafe url abort with bytestr() on url Differential Revision: https://phab.mercurial-scm.org/D2669
mercurial/util.py
--- a/mercurial/util.py	Sun Mar 04 15:16:42 2018 -0500
+++ b/mercurial/util.py	Sun Mar 04 15:55:55 2018 -0500
@@ -3097,7 +3097,7 @@
     path = urlreq.unquote(path)
     if path.startswith('ssh://-') or path.startswith('svn+ssh://-'):
         raise error.Abort(_('potentially unsafe url: %r') %
-                          (path,))
+                          (pycompat.bytestr(path),))
 
 def hidepassword(u):
     '''hide user credential in a url string'''