mercurial/dirstate.py
branchstable
changeset 17984 b74361cf7c0a
parent 17879 7b0b1da49f15
child 17987 1683bca31752
child 18076 3bc21f6daac4
equal deleted inserted replaced
17981:e689b0d91546 17984:b74361cf7c0a
   259                     self.normallookup(f)
   259                     self.normallookup(f)
   260         return copies
   260         return copies
   261 
   261 
   262     def setbranch(self, branch):
   262     def setbranch(self, branch):
   263         # no repo object here, just check for reserved names
   263         # no repo object here, just check for reserved names
   264         scmutil.checknewlabel(None, branch, 'branch')
       
   265         self._branch = encoding.fromlocal(branch)
   264         self._branch = encoding.fromlocal(branch)
   266         f = self._opener('branch', 'w', atomictemp=True)
   265         f = self._opener('branch', 'w', atomictemp=True)
   267         try:
   266         try:
   268             f.write(self._branch + '\n')
   267             f.write(self._branch + '\n')
   269         finally:
   268         finally: