diff options
| author | Dan Nicolaescu | 2008-12-12 00:54:31 +0000 |
|---|---|---|
| committer | Dan Nicolaescu | 2008-12-12 00:54:31 +0000 |
| commit | 97c6058a7a48f149d88ec2c9ed1c70f5c0449ff5 (patch) | |
| tree | c1f0b30ac31cdb04ea4c30502082fc77310f8dc6 /src | |
| parent | 2cf6bf632ffda40cb6ae59fea1141b2549b587c4 (diff) | |
| download | emacs-97c6058a7a48f149d88ec2c9ed1c70f5c0449ff5.tar.gz emacs-97c6058a7a48f149d88ec2c9ed1c70f5c0449ff5.zip | |
(init_tty): Move setting the terminal name before the
potential user: maybe_fatal.
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 5 | ||||
| -rw-r--r-- | src/term.c | 5 |
2 files changed, 8 insertions, 2 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 6cf3d1610d8..daeca39e9bf 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2008-12-12 Dan Nicolaescu <dann@ics.uci.edu> | ||
| 2 | |||
| 3 | * term.c (init_tty): Move setting the terminal name before the | ||
| 4 | potential user: maybe_fatal. | ||
| 5 | |||
| 1 | 2008-12-11 Chong Yidong <cyd@stupidchicken.com> | 6 | 2008-12-11 Chong Yidong <cyd@stupidchicken.com> |
| 2 | 7 | ||
| 3 | * term.c (tty_free_frame_resources): Renamed from | 8 | * term.c (tty_free_frame_resources): Renamed from |
diff --git a/src/term.c b/src/term.c index fd1590547c1..4beb90dc014 100644 --- a/src/term.c +++ b/src/term.c | |||
| @@ -3402,6 +3402,9 @@ init_tty (char *name, char *terminal_type, int must_succeed) | |||
| 3402 | fd = emacs_open (name, O_RDWR | O_NOCTTY, 0); | 3402 | fd = emacs_open (name, O_RDWR | O_NOCTTY, 0); |
| 3403 | #endif /* O_IGNORE_CTTY */ | 3403 | #endif /* O_IGNORE_CTTY */ |
| 3404 | 3404 | ||
| 3405 | tty->name = xstrdup (name); | ||
| 3406 | terminal->name = xstrdup (name); | ||
| 3407 | |||
| 3405 | if (fd < 0) | 3408 | if (fd < 0) |
| 3406 | maybe_fatal (must_succeed, terminal, | 3409 | maybe_fatal (must_succeed, terminal, |
| 3407 | "Could not open file: %s", | 3410 | "Could not open file: %s", |
| @@ -3422,8 +3425,6 @@ init_tty (char *name, char *terminal_type, int must_succeed) | |||
| 3422 | #endif | 3425 | #endif |
| 3423 | 3426 | ||
| 3424 | file = fdopen (fd, "w+"); | 3427 | file = fdopen (fd, "w+"); |
| 3425 | tty->name = xstrdup (name); | ||
| 3426 | terminal->name = xstrdup (name); | ||
| 3427 | tty->input = file; | 3428 | tty->input = file; |
| 3428 | tty->output = file; | 3429 | tty->output = file; |
| 3429 | } | 3430 | } |