Importing Gnus v5.8.6.
[elisp/gnus.git-] / lisp / gnus-util.el
index 6c5bf66..1df730a 100644 (file)
        (and (string-match "(.*" from)
             (setq name (substring from (1+ (match-beginning 0))
                                   (match-end 0)))))
-    ;; Fix by Hallvard B Furuseth <h.b.furuseth@usit.uio.no>.
-    (list (or name from) (or address from))))
+    (list (if (string= name "") nil name) (or address from))))
+
 
 (defun gnus-fetch-field (field)
   "Return the value of the header FIELD of current article."
@@ -873,7 +873,8 @@ ARG is passed to the first function."
       (setq result (nreverse result))
       (while (and result
                  (not (equal (or port "nntp")
-                             (gnus-netrc-get (car result) "port"))))
+                             (or (gnus-netrc-get (car result) "port")
+                                 "nntp"))))
        (pop result))
       (car result))))