branch | stable |
changeset 10417 | 58e040c51231 |
parent 10263 | 25e572394f5c |
child 10420 | 41d0ed2c79df |
--- a/mercurial/dirstate.py Sun Feb 07 11:38:36 2010 +0100 +++ b/mercurial/dirstate.py Thu Feb 11 12:02:48 2010 -0200 @@ -202,6 +202,8 @@ self._pl = p1, p2 def setbranch(self, branch): + if branch in ['tip', '.', 'null']: + raise util.Abort(_('the name \'%s\' is reserved') % branch) self._branch = branch self._opener("branch", "w").write(branch + '\n')