diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2018-07-14 21:03:06 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2018-07-14 21:03:06 +0100 |
commit | 8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch) | |
tree | 7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /dev-vcs/darcs/files/darcs-2.8.4-fix-nonatomic-global.patch | |
parent | 30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff) |
gentoo resync : 14.07.2018
Diffstat (limited to 'dev-vcs/darcs/files/darcs-2.8.4-fix-nonatomic-global.patch')
-rw-r--r-- | dev-vcs/darcs/files/darcs-2.8.4-fix-nonatomic-global.patch | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/dev-vcs/darcs/files/darcs-2.8.4-fix-nonatomic-global.patch b/dev-vcs/darcs/files/darcs-2.8.4-fix-nonatomic-global.patch new file mode 100644 index 000000000000..c3fce6fbc9e8 --- /dev/null +++ b/dev-vcs/darcs/files/darcs-2.8.4-fix-nonatomic-global.patch @@ -0,0 +1,20 @@ +There is a bug in speculateFileOrUrl. +It puts downloaded file nonatomically. + +There is a window when copyFileOrUrl can (and does) +copy partially downloaded file. + +Darcs-bug: http://bugs.darcs.net/issue2364 +diff --git a/src/Darcs/External.hs b/src/Darcs/External.hs +index 2e0e791..d5a0b9f 100644 +--- a/src/Darcs/External.hs ++++ b/src/Darcs/External.hs +@@ -184,7 +184,7 @@ copyFileOrUrl rd fou out _ | isSshUrl fou = copySSH rd (splitSshUrl fou) + copyFileOrUrl _ fou _ _ = fail $ "unknown transport protocol: " ++ fou + + speculateFileOrUrl :: String -> FilePath -> IO () +-speculateFileOrUrl fou out | isHttpUrl fou = speculateRemote fou out ++speculateFileOrUrl fou out | isHttpUrl fou = speculateRemote fou out >> waitUrl fou + | otherwise = return () + + copyLocal :: String -> FilePath -> IO () |