Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
9997dc15
Commit
9997dc15
authored
Feb 08, 2008
by
Stefan Monnier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(decode_options): Pass --display implicitly if -c
is specified. Only set tty if -t or -c is specified.
parent
fe243f8e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
10 deletions
+17
-10
lib-src/ChangeLog
lib-src/ChangeLog
+5
-0
lib-src/emacsclient.c
lib-src/emacsclient.c
+12
-10
No files found.
lib-src/ChangeLog
View file @
9997dc15
2008-02-08 Stefan Monnier <monnier@iro.umontreal.ca>
* emacsclient.c (decode_options): Pass --display implicitly if -c
is specified. Only set tty if -t or -c is specified.
2008-02-04 Jason Rumney <jasonr@gnu.org>
* makefile.w32-in (lisp1): Use (), not {}.
...
...
lib-src/emacsclient.c
View file @
9997dc15
...
...
@@ -480,15 +480,6 @@ decode_options (argc, argv)
{
alternate_editor
=
egetenv
(
"ALTERNATE_EDITOR"
);
/* We used to set `display' to $DISPLAY by default, but this changed the
default behavior and is sometimes inconvenient. So instead of forcing
users to say "--display ''" when they want to use Emacs's existing tty
or display connection, we force them to use "--display $DISPLAY" if
they want Emacs to connect to their current display. */
#if 0
display = egetenv ("DISPLAY");
#endif
while
(
1
)
{
int
opt
=
getopt_long
(
argc
,
argv
,
...
...
@@ -566,13 +557,24 @@ decode_options (argc, argv)
}
}
/* We used to set `display' to $DISPLAY by default, but this changed the
default behavior and is sometimes inconvenient. So instead of forcing
users to say "--display ''" when they want to use Emacs's existing tty
or display connection, we force them to use "--display $DISPLAY" if
they want Emacs to connect to their current display.
-c still implicitly passes --display $DISPLAY unless -t was specified
so as to try and mimick the behavior of `emacs' which either uses
the current tty or the current $DISPLAY. */
if
(
!
current_frame
&&
!
tty
)
display
=
egetenv
(
"DISPLAY"
);
if
(
display
&&
strlen
(
display
)
==
0
)
display
=
NULL
;
if
(
!
tty
&&
display
)
window_system
=
1
;
#if !defined (WINDOWSNT) && !defined (HAVE_CARBON)
else
else
if
(
!
current_frame
)
tty
=
1
;
#endif
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment