git-annex/Utility
Joey Hess b8f0b7309f Work around curl bug when asked to download an empty url to a file.
In this situation, curl -o exits successfully without creating the output
file.

There was already a workaround for curl file:/// but I did not realize this
also affected regular url downloads.

To fix it, pre-create the destination file before starting curl.
Since we cannot always know the size of an url before trying to download
it, let's always do this.

Note that since curl is told -C -, we have to consider if this
makes curl try to do a ranged download, which might fail on some servers
where a regular download would have succeeded. My testing indicates
this isn't a problem; since the file is empty, curl seems to not try to
do a ranged download.

Original report: https://github.com/datalad/datalad/issues/79
Curl bug report: https://github.com/bagder/curl/issues/183
2015-03-27 10:22:36 -04:00
..
DirWatcher update my email address and homepage url 2015-01-21 12:50:09 -04:00
LockFile update my email address and homepage url 2015-01-21 12:50:09 -04:00
Applicative.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Base64.hs metadata: Fix encoding problem that led to mojibake when storing metadata strings that contained both unicode characters and a space (or '!') character. 2015-03-04 12:54:30 -04:00
Batch.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Bloom.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
CoProcess.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
CopyFile.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Daemon.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Data.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
DataUnits.hs merge change from propellor 2015-01-21 23:13:50 -04:00
DBus.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Directory.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
DirWatcher.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
DiskFree.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Dot.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
DottedVersion.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Env.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Exception.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
ExternalSHA.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
FileMode.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
FileSize.hs build fix 2015-01-20 17:27:42 -04:00
FileSystemEncoding.hs metadata: Fix encoding problem that led to mojibake when storing metadata strings that contained both unicode characters and a space (or '!') character. 2015-03-04 12:54:30 -04:00
Format.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
FreeDesktop.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Glob.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Gpg.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Hash.hs Added MD5 and MD5E backends. 2015-02-04 13:47:54 -04:00
HumanNumber.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
HumanTime.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
InodeCache.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
JSONStream.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
libdiskfree.c update my email address and homepage url 2015-01-21 12:50:09 -04:00
libdiskfree.h
libkqueue.c update my email address and homepage url 2015-01-21 12:50:09 -04:00
libkqueue.h
libmounts.c update my email address and homepage url 2015-01-21 12:50:09 -04:00
libmounts.h
LinuxMkLibs.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
LockFile.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
LogFile.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Lsof.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Matcher.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Metered.hs bittorrent: Fix mojibake introduced in parsing arai2c progress output. 2015-02-10 12:34:34 -04:00
Misc.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Monad.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Mounts.hsc update my email address and homepage url 2015-01-21 12:50:09 -04:00
Network.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
NotificationBroadcaster.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
OSX.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Parallel.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
PartialPrelude.hs
Path.hs Windows: Fix bug in dropping an annexed file, which caused a symlink to be staged that contained backslashes. 2015-02-09 15:37:26 -04:00
Percentage.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
PID.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
PosixFiles.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Process.hs Fix build with process 1.2.1.0. 2015-01-04 13:07:57 -04:00
QuickCheck.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Quvi.hs fix intentional typo left in after debugging session, broke quvi support (last release is ok) 2015-02-19 14:31:04 -04:00
Rsync.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
SafeCommand.hs update comment for segmentXargs 2015-03-26 13:48:12 -04:00
Scheduled.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Shell.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
SimpleProtocol.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
SRV.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
SshConfig.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Tense.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
ThreadLock.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
ThreadScheduler.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
TList.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Tmp.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Touch.hsc update my email address and homepage url 2015-01-21 12:50:09 -04:00
URI.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Url.hs Work around curl bug when asked to download an empty url to a file. 2015-03-27 10:22:36 -04:00
UserInfo.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Verifiable.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
WebApp.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
winprocess.c windows: Fix process termination code. 2014-02-13 15:53:10 -04:00
WinProcess.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00
Yesod.hs update my email address and homepage url 2015-01-21 12:50:09 -04:00