[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
03/04: http-client: 'http-fetch' converts strings to URIs.
From: |
Ludovic Courtès |
Subject: |
03/04: http-client: 'http-fetch' converts strings to URIs. |
Date: |
Sun, 29 Nov 2015 18:18:57 +0000 |
civodul pushed a commit to branch master
in repository guix.
commit 25d188ce12e4e192e4167d03728a8ff69fe0bb35
Author: Ludovic Courtès <address@hidden>
Date: Sun Nov 29 17:46:11 2015 +0100
http-client: 'http-fetch' converts strings to URIs.
* guix/http-client.scm (http-fetch): Use 'string->uri' if URI is a
string. Fixes a regression introduced in 8a5063f.
---
guix/http-client.scm | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/guix/http-client.scm b/guix/http-client.scm
index aa873a4..eb2c3f4 100644
--- a/guix/http-client.scm
+++ b/guix/http-client.scm
@@ -207,7 +207,9 @@ textual. Follow any HTTP redirection. When BUFFERED? is
#f, return an
unbuffered port, suitable for use in `filtered-port'.
Raise an '&http-get-error' condition if downloading fails."
- (let loop ((uri uri))
+ (let loop ((uri (if (string? uri)
+ (string->uri uri)
+ uri)))
(let ((port (or port (open-connection-for-uri uri))))
(unless buffered?
(setvbuf port _IONBF))