mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 15:27:13 +03:00
ui: disallow newlines in usernames (issue1034)
This commit is contained in:
parent
9454e6e5aa
commit
06bb84cfa6
@ -351,6 +351,8 @@ class ui(object):
|
||||
pass
|
||||
if not user:
|
||||
raise util.Abort(_("Please specify a username."))
|
||||
if "\n" in user:
|
||||
raise util.Abort(_("username %s contains a newline\n") % `user`)
|
||||
return user
|
||||
|
||||
def shortuser(self, user):
|
||||
|
Loading…
Reference in New Issue
Block a user