summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2016-03-16 10:20:45 +0100
committerLudovic Courtès <ludo@gnu.org>2016-03-16 11:27:37 +0100
commit409e4ac6e3d86491901a9c0bb422b0415c906964 (patch)
tree9c67eac67dfecb8cd1b157e2ac78acffe9a5564b
parent247d498aaa7938efe9acbd83ea8721e477a7236d (diff)
http-client: No 'setvbuf' for non-file ports.
* guix/http-client.scm (http-fetch): Do not call 'setvbuf' on non-file ports.
-rw-r--r--guix/http-client.scm2
1 files changed, 1 insertions, 1 deletions
diff --git a/guix/http-client.scm b/guix/http-client.scm
index 25693824ed..97a1e26d3e 100644
--- a/guix/http-client.scm
+++ b/guix/http-client.scm
@@ -243,7 +243,7 @@ Raise an '&http-get-error' condition if downloading fails."
(base64-encode
(string->utf8 str))))))
(_ '()))))
- (unless buffered?
+ (unless (or buffered? (not (file-port? port)))
(setvbuf port _IONBF))
(let*-values (((resp data)
;; Try hard to use the API du jour to get an input port.