X-Git-Url: http://git.hcoop.net/bpt/emacs.git/blobdiff_plain/5725bd2cc0e691dadc31bd958f210b1bbcf17c49..279f9b06fd693b67d1178cdb5ad1ecf513d199ad:/src/terminal.c
diff --git a/src/terminal.c b/src/terminal.c
index 53610d9736..854ca61f19 100644
--- a/src/terminal.c
+++ b/src/terminal.c
@@ -17,8 +17,10 @@ You should have received a copy of the GNU General Public License
along with GNU Emacs. If not, see . */
#include
+
+#define TERMHOOKS_INLINE EXTERN_INLINE
+
#include
-#include
#include "lisp.h"
#include "frame.h"
@@ -39,6 +41,13 @@ struct terminal *initial_terminal;
static void delete_initial_terminal (struct terminal *);
+/* This setter is used only in this file, so it can be private. */
+static void
+tset_param_alist (struct terminal *t, Lisp_Object val)
+{
+ t->param_alist = val;
+}
+
void
@@ -284,7 +293,7 @@ delete_terminal (struct terminal *terminal)
for (tp = &terminal_list; *tp != terminal; tp = &(*tp)->next_terminal)
if (! *tp)
- abort ();
+ emacs_abort ();
*tp = terminal->next_terminal;
xfree (terminal->keyboard_coding);
@@ -351,14 +360,7 @@ If FRAME is nil, the selected frame is used.
The terminal device is represented by its integer identifier. */)
(Lisp_Object frame)
{
- struct terminal *t;
-
- if (NILP (frame))
- frame = selected_frame;
-
- CHECK_LIVE_FRAME (frame);
-
- t = FRAME_TERMINAL (XFRAME (frame));
+ struct terminal *t = FRAME_TERMINAL (decode_live_frame (frame));
if (!t)
return Qnil;
@@ -401,7 +403,7 @@ possible return values. */)
case output_ns:
return Qns;
default:
- abort ();
+ emacs_abort ();
}
}
@@ -446,7 +448,7 @@ store_terminal_param (struct terminal *t, Lisp_Object parameter, Lisp_Object val
Lisp_Object old_alist_elt = Fassq (parameter, t->param_alist);
if (EQ (old_alist_elt, Qnil))
{
- TSET (t, param_alist, Fcons (Fcons (parameter, value), t->param_alist));
+ tset_param_alist (t, Fcons (Fcons (parameter, value), t->param_alist));
return Qnil;
}
else
@@ -509,7 +511,7 @@ struct terminal *
init_initial_terminal (void)
{
if (initialized || terminal_list || tty_list)
- abort ();
+ emacs_abort ();
initial_terminal = create_terminal ();
initial_terminal->type = output_initial;
@@ -528,7 +530,7 @@ static void
delete_initial_terminal (struct terminal *terminal)
{
if (terminal != initial_terminal)
- abort ();
+ emacs_abort ();
delete_terminal (terminal);
initial_terminal = NULL;