diff options
author | Ludovic Courtès <ludo@gnu.org> | 2015-09-13 21:28:01 +0200 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2015-09-13 21:28:01 +0200 |
commit | 75710da66710cef1d32053cd8f350d13057d02a7 (patch) | |
tree | abef6a326c741b1eb18db866b2f2bacee3e5fc51 /guix/http-client.scm | |
parent | ab20c2cc33063ce783515d8ae7899ec7e2ca6f96 (diff) | |
parent | 610075f7c94c80b8321887b7ccf8bb1a7edd2b8e (diff) |
Merge branch 'master' into core-updates
Diffstat (limited to 'guix/http-client.scm')
-rw-r--r-- | guix/http-client.scm | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/guix/http-client.scm b/guix/http-client.scm index dc8d3298fc..5cfe05f2e0 100644 --- a/guix/http-client.scm +++ b/guix/http-client.scm @@ -19,7 +19,6 @@ ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. (define-module (guix http-client) - #:use-module (guix utils) #:use-module (web uri) #:use-module ((web client) #:hide (open-socket-for-uri)) #:use-module (web response) @@ -167,13 +166,15 @@ closes PORT, unless KEEP-ALIVE? is true." (define close (and (not keep-alive?) (lambda () - (close port)))) + (close-port port)))) (make-custom-binary-input-port "delimited input port" read! #f #f close)) - (unless (guile-version>? "2.0.9") + (unless (guile-version>? "2.0.11") ;; Guile <= 2.0.9 had a bug whereby 'response-body-port' would read more ;; than what 'content-length' says. See Guile commit 802a25b. + ;; Guile <= 2.0.12 had a bug whereby the 'close' method of the response + ;; body port would fail with wrong-arg-num. See Guile commit 5a10e41. (module-set! (resolve-module '(web response)) 'make-delimited-input-port make-delimited-input-port))) |