]> code.delx.au - gnu-emacs/blobdiff - lisp/url/url-parse.el
Move low-level library files from the lisp/gnus directory
[gnu-emacs] / lisp / url / url-parse.el
index dbf0c38687193843557f8e64c8921a984f9ac448..6e51b35f5a1ebbe4e997cd6d8761af528500811b 100644 (file)
@@ -1,6 +1,6 @@
 ;;; url-parse.el --- Uniform Resource Locator parser
 
-;; Copyright (C) 1996-1999, 2004-2015 Free Software Foundation, Inc.
+;; Copyright (C) 1996-1999, 2004-2016 Free Software Foundation, Inc.
 
 ;; Keywords: comm, data, processes
 
@@ -59,8 +59,6 @@ where each of PATH and QUERY are strings or nil."
          (setq path  (substring name 0 (match-beginning 0))
                query (substring name (match-end 0)))
        (setq path name)))
-    (if (equal path "") (setq path nil))
-    (if (equal query "") (setq query nil))
     (cons path query)))
 
 (defun url-port-if-non-default (urlobj)
@@ -217,8 +215,7 @@ parses to
            (when (looking-at "#")
              (let ((opoint (point)))
                (forward-char 1)
-               (unless (eobp)
-                 (setq fragment (buffer-substring (point) (point-max))))
+                (setq fragment (buffer-substring (point) (point-max)))
                (delete-region opoint (point-max)))))
 
           (if (and host (string-match "%[0-9][0-9]" host))