emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] emacs-26 19fa6d5 1/2: Fix --no-build-details for w32 and m


From: Noam Postavsky
Subject: [Emacs-diffs] emacs-26 19fa6d5 1/2: Fix --no-build-details for w32 and macOS
Date: Thu, 8 Feb 2018 19:14:14 -0500 (EST)

branch: emacs-26
commit 19fa6d561abd91e9ad71a6799c5ed4f582c9f351
Author: Noam Postavsky <address@hidden>
Commit: Noam Postavsky <address@hidden>

    Fix --no-build-details for w32 and macOS
    
    * src/w32term.c (w32_initialize_display_info): Handle nil system-name.
    * lisp/term/ns-win.el (window-system-initialization): Don't pass nil
    to `x-open-connection'.
---
 lisp/term/ns-win.el |  2 +-
 src/w32term.c       | 13 +++++++++----
 2 files changed, 10 insertions(+), 5 deletions(-)

diff --git a/lisp/term/ns-win.el b/lisp/term/ns-win.el
index 618041d..76b1a41 100644
--- a/lisp/term/ns-win.el
+++ b/lisp/term/ns-win.el
@@ -834,7 +834,7 @@ See the documentation of `create-fontset-from-fontset-spec' 
for the format.")
             (format "Creation of the standard fontset failed: %s" err)
             :error)))
 
-  (x-open-connection (system-name) x-command-line-resources t)
+  (x-open-connection (or (system-name) "") x-command-line-resources t)
 
   ;; Add GNUstep menu items Services, Hide and Quit.  Rename Help to Info
   ;; and put it first (i.e. omit from menu-bar-final-items.
diff --git a/src/w32term.c b/src/w32term.c
index db4ccf5..ac29bbb 100644
--- a/src/w32term.c
+++ b/src/w32term.c
@@ -6922,10 +6922,15 @@ w32_initialize_display_info (Lisp_Object display_name)
   memset (dpyinfo, 0, sizeof (*dpyinfo));
 
   dpyinfo->name_list_element = Fcons (display_name, Qnil);
-  dpyinfo->w32_id_name = xmalloc (SCHARS (Vinvocation_name)
-                                 + SCHARS (Vsystem_name) + 2);
-  sprintf (dpyinfo->w32_id_name, "address@hidden",
-          SDATA (Vinvocation_name), SDATA (Vsystem_name));
+  if (STRINGP (Vsystem_name))
+    {
+      dpyinfo->w32_id_name = xmalloc (SCHARS (Vinvocation_name)
+                                      + SCHARS (Vsystem_name) + 2);
+      sprintf (dpyinfo->w32_id_name, "address@hidden",
+               SDATA (Vinvocation_name), SDATA (Vsystem_name));
+    }
+  else
+    dpyinfo->w32_id_name = xlispstrdup (Vinvocation_name);
 
   /* Default Console mode values - overridden when running in GUI mode
      with values obtained from system metrics.  */



reply via email to

[Prev in Thread] Current Thread [Next in Thread]