From 8536c0f5c5536ed023c61c6f903abbef805f2715 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Thu, 30 Oct 2008 15:54:38 +0000 Subject: [PATCH] (main): If using the current frame, send tty information to Emacs in case daemon mode needs to occupy this tty. --- lib-src/emacsclient.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib-src/emacsclient.c b/lib-src/emacsclient.c index 870100ed4af..0bbc385d07f 100644 --- a/lib-src/emacsclient.c +++ b/lib-src/emacsclient.c @@ -1437,7 +1437,10 @@ main (argc, argv) send_to_emacs (emacs_socket, " "); } - if (tty) + /* If using the current frame, send tty information to Emacs anyway. + In daemon mode, Emacs may need to occupy this tty if no other + frame is available. */ + if (tty || current_frame) { char *type = egetenv ("TERM"); char *tty_name = NULL; -- 2.39.5