mercurial/localrepo.py
changeset 50265 240a04cedd24
parent 50195 11e6eee4b063
child 50267 f92afdf3cff9
equal deleted inserted replaced
50264:921f4834b7b5 50265:240a04cedd24
  2673         # strip" to pick a working copy destination on `hg rollback`
  2673         # strip" to pick a working copy destination on `hg rollback`
  2674         if self.currentwlock() is not None:
  2674         if self.currentwlock() is not None:
  2675             ds = self.dirstate
  2675             ds = self.dirstate
  2676             if ds.branch() == b'default':
  2676             if ds.branch() == b'default':
  2677                 # force a file to be written if None exist
  2677                 # force a file to be written if None exist
  2678                 ds.setbranch(b'default')
  2678                 ds.setbranch(b'default', None)
  2679             # we cannot simply add "branch" to `all_file_names` because branch
  2679             # we cannot simply add "branch" to `all_file_names` because branch
  2680             # is written outside of the transaction control. So we need to
  2680             # is written outside of the transaction control. So we need to
  2681             # backup early.
  2681             # backup early.
  2682             tr.addbackup(b"branch", hardlink=True, location=b'plain')
  2682             tr.addbackup(b"branch", hardlink=True, location=b'plain')
  2683 
  2683