diff options
author | Julian Andres Klode <jak@debian.org> | 2010-06-29 17:28:33 +0200 |
---|---|---|
committer | Julian Andres Klode <jak@debian.org> | 2010-06-29 17:28:33 +0200 |
commit | fd3b761e8cba6ed626639b50b1221246098c7b3a (patch) | |
tree | d2e588d053604bd94e5de2443cd3cb422177a691 /apt-pkg/contrib/fileutl.cc | |
parent | 3010fb0e069d2fd4c7a6ade4559bfb659bf8f2fb (diff) |
Fix the atomic replace.
Diffstat (limited to 'apt-pkg/contrib/fileutl.cc')
-rw-r--r-- | apt-pkg/contrib/fileutl.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apt-pkg/contrib/fileutl.cc b/apt-pkg/contrib/fileutl.cc index 0b0739cda..0b62d1bd8 100644 --- a/apt-pkg/contrib/fileutl.cc +++ b/apt-pkg/contrib/fileutl.cc @@ -843,9 +843,9 @@ bool FileFd::Close() iFd = -1; if ((Flags & Replace) == Replace) { - FileName = TemporaryFileName; // for the unlink() below. if (rename(TemporaryFileName.c_str(), FileName.c_str()) != 0) Res &= _error->Errno("rename",_("Problem renaming the file")); + FileName = TemporaryFileName; // for the unlink() below. } if ((Flags & Fail) == Fail && (Flags & DelOnFail) == DelOnFail && |