curl/0002-curl-7.21.1-5907777.patch
Kamil Dudka ec7f823e5f fixes for rhbz #617757 and #622520
Both of them are already pushed upstream.
2010-08-19 15:59:54 +02:00

37 lines
1.0 KiB
Diff

CHANGES | 5 +++++
src/main.c | 5 ++++-
2 files changed, 9 insertions(+), 1 deletions(-)
diff --git a/CHANGES b/CHANGES
index 35868ff..1e3a501 100644
--- a/CHANGES
+++ b/CHANGES
@@ -6,6 +6,11 @@
Changelog
+Kamil Dudka (15 Aug 2010)
+- curl -T: ignore file size of special files
+
+ original bug report at https://bugzilla.redhat.com/622520
+
Kamil Dudka (12 Aug 2010)
- typecheck-gcc: work around gcc upstream bug #32061
diff --git a/src/main.c b/src/main.c
index 5585c17..3b78d60 100644
--- a/src/main.c
+++ b/src/main.c
@@ -4925,7 +4925,10 @@ operate(struct Configurable *config, int argc, argv_item_t argv[])
goto quit_urls;
}
infdopen=TRUE;
- uploadfilesize=fileinfo.st_size;
+
+ /* we ignore file size for char/block devices, sockets, etc. */
+ if(S_IFREG == (fileinfo.st_mode & S_IFMT))
+ uploadfilesize=fileinfo.st_size;
}
else if(uploadfile && stdin_upload(uploadfile)) {