mercurial/repo.py
author mason@suse.com
Tue, 04 Apr 2006 16:38:44 -0400
changeset 2076 d007df6daf8e
parent 1089 142b5d5ec9cc
child 2612 ffb895f16925
permissions -rw-r--r--
Create an atomic opener that does not automatically rename on close The revlog.checkinlinesize() uses an atomic opener to replace the index file after converting it from inline to traditional .i and .d files. If this operation is interrupted, the atomic file class can overwrite a valid file with a partially written one. This patch introduces an atomic opener that does not automatically replace the destination file with the tempfile. This way an interrupted checkinlinesize() call turns into a noop.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1089
142b5d5ec9cc Break apart hg.py
mpm@selenic.com
parents:
diff changeset
     1
# repo.py - repository base classes for mercurial
142b5d5ec9cc Break apart hg.py
mpm@selenic.com
parents:
diff changeset
     2
#
142b5d5ec9cc Break apart hg.py
mpm@selenic.com
parents:
diff changeset
     3
# Copyright 2005 Matt Mackall <mpm@selenic.com>
142b5d5ec9cc Break apart hg.py
mpm@selenic.com
parents:
diff changeset
     4
#
142b5d5ec9cc Break apart hg.py
mpm@selenic.com
parents:
diff changeset
     5
# This software may be used and distributed according to the terms
142b5d5ec9cc Break apart hg.py
mpm@selenic.com
parents:
diff changeset
     6
# of the GNU General Public License, incorporated herein by reference.
142b5d5ec9cc Break apart hg.py
mpm@selenic.com
parents:
diff changeset
     7
142b5d5ec9cc Break apart hg.py
mpm@selenic.com
parents:
diff changeset
     8
class RepoError(Exception): pass