shr.el (shr-expand-url): Handle URL starting with `//'
[gnus] / lisp / shr.el
index bf6e57e..e7a6c5d 100644 (file)
@@ -484,6 +484,9 @@ size, and full-buffer size."
        (string-match "\\`[a-z]*:" url)
        (not shr-base))
     url)
+   ((and (string-match "\\`//" url)
+        (string-match "\\`[a-z]*:" shr-base))
+    (concat (match-string 0 shr-base) url))
    ((and (not (string-match "/\\'" shr-base))
         (not (string-match "\\`/" url)))
     (concat shr-base "/" url))