aboutsummaryrefslogtreecommitdiff
path: root/contrib/ncurses/ncurses/tinfo
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/ncurses/ncurses/tinfo')
-rw-r--r--contrib/ncurses/ncurses/tinfo/lib_data.c37
-rw-r--r--contrib/ncurses/ncurses/tinfo/lib_setup.c25
2 files changed, 53 insertions, 9 deletions
diff --git a/contrib/ncurses/ncurses/tinfo/lib_data.c b/contrib/ncurses/ncurses/tinfo/lib_data.c
index 225935ea79f0..21b854b92b6f 100644
--- a/contrib/ncurses/ncurses/tinfo/lib_data.c
+++ b/contrib/ncurses/ncurses/tinfo/lib_data.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * Copyright (c) 1998-2005,2007 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
@@ -41,7 +41,7 @@
#include <curses.priv.h>
-MODULE_ID("$Id: lib_data.c,v 1.34 2007/10/20 21:49:10 tom Exp $")
+MODULE_ID("$Id: lib_data.c,v 1.39 2008/01/13 01:21:59 tom Exp $")
/*
* OS/2's native linker complains if we don't initialize public data when
@@ -131,6 +131,8 @@ NCURSES_EXPORT_VAR(NCURSES_GLOBALS) _nc_globals = {
NULL, /* first_name */
NULL, /* keyname_table */
+ 0, /* slk_format */
+
NULL, /* safeprint_buf */
0, /* safeprint_used */
@@ -177,10 +179,10 @@ NCURSES_EXPORT_VAR(NCURSES_GLOBALS) _nc_globals = {
#endif /* TRACE */
#ifdef USE_PTHREADS
- PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP, /* mutex_set_SP */
- PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP, /* mutex_use_screen */
- PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP, /* mutex_use_window */
- PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP, /* mutex_windowlist */
+ PTHREAD_MUTEX_INITIALIZER, /* mutex_set_SP */
+ PTHREAD_MUTEX_INITIALIZER, /* mutex_use_screen */
+ PTHREAD_MUTEX_INITIALIZER, /* mutex_use_window */
+ PTHREAD_MUTEX_INITIALIZER, /* mutex_windowlist */
PTHREAD_MUTEX_INITIALIZER, /* mutex_tst_tracef */
PTHREAD_MUTEX_INITIALIZER, /* mutex_tracef */
0, /* nested_tracef */
@@ -191,7 +193,7 @@ NCURSES_EXPORT_VAR(NCURSES_GLOBALS) _nc_globals = {
#define STACK_FRAME_0s { STACK_FRAME_0 }
#define NUM_VARS_0s { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 }
-#define RIPOFF_0 { 0,0 }
+#define RIPOFF_0 { 0,0,0 }
#define RIPOFF_0s { RIPOFF_0 }
NCURSES_EXPORT_VAR(NCURSES_PRESCREEN) _nc_prescreen = {
@@ -231,3 +233,24 @@ NCURSES_EXPORT_VAR(NCURSES_PRESCREEN) _nc_prescreen = {
#endif
};
/* *INDENT-ON* */
+
+/******************************************************************************/
+#ifdef USE_PTHREADS
+NCURSES_EXPORT(int)
+_nc_mutex_lock(pthread_mutex_t *obj)
+{
+ return pthread_mutex_lock(obj);
+}
+
+NCURSES_EXPORT(int)
+_nc_mutex_trylock(pthread_mutex_t *obj)
+{
+ return pthread_mutex_trylock(obj);
+}
+
+NCURSES_EXPORT(int)
+_nc_mutex_unlock(pthread_mutex_t *obj)
+{
+ return pthread_mutex_unlock(obj);
+}
+#endif /* USE_PTHREADS */
diff --git a/contrib/ncurses/ncurses/tinfo/lib_setup.c b/contrib/ncurses/ncurses/tinfo/lib_setup.c
index 1a061e083f28..a376fc60275b 100644
--- a/contrib/ncurses/ncurses/tinfo/lib_setup.c
+++ b/contrib/ncurses/ncurses/tinfo/lib_setup.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * Copyright (c) 1998-2006,2007 Free Software Foundation, Inc. *
+ * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc. *
* *
* Permission is hereby granted, free of charge, to any person obtaining a *
* copy of this software and associated documentation files (the *
@@ -53,7 +53,7 @@
#include <term.h> /* lines, columns, cur_term */
-MODULE_ID("$Id: lib_setup.c,v 1.100 2007/09/01 20:58:26 tom Exp $")
+MODULE_ID("$Id: lib_setup.c,v 1.102 2008/01/19 21:07:45 tom Exp $")
/****************************************************************************
*
@@ -99,6 +99,9 @@ MODULE_ID("$Id: lib_setup.c,v 1.100 2007/09/01 20:58:26 tom Exp $")
# endif
#endif
+/*
+ * Wrap global variables in this module.
+ */
#if USE_REENTRANT
NCURSES_EXPORT(char *)
NCURSES_PUBLIC_VAR(ttytype) (void)
@@ -128,6 +131,24 @@ NCURSES_EXPORT_VAR(int) COLS = 0;
NCURSES_EXPORT_VAR(int) TABSIZE = 0;
#endif
+#if NCURSES_EXT_FUNCS
+NCURSES_EXPORT(int)
+set_tabsize(int value)
+{
+ int code = OK;
+#if USE_REENTRANT
+ if (SP) {
+ SP->_TABSIZE = value;
+ } else {
+ code = ERR;
+ }
+#else
+ TABSIZE = value;
+#endif
+ return code;
+}
+#endif
+
#if USE_SIGWINCH
/*
* If we have a pending SIGWINCH, set the flag in each screen.