]> git.eshelyaron.com Git - emacs.git/commitdiff
Make fully qualified domain names more fully qualified
authorLars Ingebrigtsen <larsi@gnus.org>
Wed, 13 Sep 2017 16:08:34 +0000 (18:08 +0200)
committerLars Ingebrigtsen <larsi@gnus.org>
Wed, 13 Sep 2017 16:08:51 +0000 (18:08 +0200)
* lisp/gnus/message.el (message-make-fqdn): Don't try to use a
system-name without any periods as a fully qualified domain name.

lisp/gnus/message.el

index 214cf61e84d300b40560f2ab848bf141919da483..80f270a0c11422c07f3799933e54040680bc5885 100644 (file)
@@ -5778,7 +5778,10 @@ give as trustworthy answer as possible."
           (not (string-match message-bogus-system-names message-user-fqdn)))
       ;; `message-user-fqdn' seems to be valid
       message-user-fqdn)
-     ((not (string-match message-bogus-system-names sysname))
+     ;; A system name without any dots is unlikely to be a good fully
+     ;; qualified domain name.
+     ((and (string-match "[.]" sysname)
+          (not (string-match message-bogus-system-names sysname)))
       ;; `system-name' returned the right result.
       sysname)
      ;; Try `mail-host-address'.