summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChong Yidong <cyd@stupidchicken.com>2008-09-19 15:50:24 +0000
committerChong Yidong <cyd@stupidchicken.com>2008-09-19 15:50:24 +0000
commitd5dabcb513f89eb4fb4b05e966806f3df9cc157c (patch)
tree0f550222eff165670afc51ae0244d5edb1c1b011
parent997ec9575c306d8665475497aa79446db7a74477 (diff)
downloademacs-d5dabcb513f89eb4fb4b05e966806f3df9cc157c.tar.gz
emacs-d5dabcb513f89eb4fb4b05e966806f3df9cc157c.tar.bz2
emacs-d5dabcb513f89eb4fb4b05e966806f3df9cc157c.zip
(main): Use stdout rather than stdin to obtain the terminal (bug#427).
-rw-r--r--lib-src/emacsclient.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib-src/emacsclient.c b/lib-src/emacsclient.c
index 8f0231db540..87cc9de6f51 100644
--- a/lib-src/emacsclient.c
+++ b/lib-src/emacsclient.c
@@ -1429,7 +1429,7 @@ main (argc, argv)
char *type = egetenv ("TERM");
char *tty_name = NULL;
#ifndef WINDOWSNT
- tty_name = ttyname (fileno (stdin));
+ tty_name = ttyname (fileno (stdout));
#endif
if (! tty_name)