diff options
Diffstat (limited to 'lisp/nxml/rng-uri.el')
-rw-r--r-- | lisp/nxml/rng-uri.el | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lisp/nxml/rng-uri.el b/lisp/nxml/rng-uri.el index 798475bbc3d..e2bb8adfef5 100644 --- a/lisp/nxml/rng-uri.el +++ b/lisp/nxml/rng-uri.el @@ -83,10 +83,11 @@ Signal an error if URI is not a valid file URL." (cond ((not scheme) (unless pattern (rng-uri-error "URI `%s' does not have a scheme" uri))) - ((not (string= (downcase scheme) "file")) - (rng-uri-error "URI `%s' does not use the `file:' scheme" uri))) - (when (not (member authority - (cons (system-name) '(nil "" "localhost")))) + ((not (member (downcase scheme) '("file" "http"))) + (rng-uri-error "URI `%s' does not use the `file:' or `http:' scheme" uri))) + (when (and (equal (downcase scheme) "file") + (not (member authority + (cons (system-name) '(nil "" "localhost"))))) (rng-uri-error "URI `%s' does not start with `file:///' or `file://localhost/'" uri)) (when query |