diff options
Diffstat (limited to 'contrib/ncurses/ncurses/tinfo/lib_acs.c')
-rw-r--r-- | contrib/ncurses/ncurses/tinfo/lib_acs.c | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/contrib/ncurses/ncurses/tinfo/lib_acs.c b/contrib/ncurses/ncurses/tinfo/lib_acs.c index 54554a8..b84d8e2 100644 --- a/contrib/ncurses/ncurses/tinfo/lib_acs.c +++ b/contrib/ncurses/ncurses/tinfo/lib_acs.c @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (c) 1998,1999,2000 Free Software Foundation, Inc. * + * Copyright (c) 1998,1999,2000,2001 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 * @@ -34,12 +34,23 @@ #include <curses.priv.h> #include <term.h> /* ena_acs, acs_chars */ -MODULE_ID("$Id: lib_acs.c,v 1.18 2000/12/10 02:55:07 tom Exp $") +MODULE_ID("$Id: lib_acs.c,v 1.21 2001/12/23 00:15:10 tom Exp $") +#if BROKEN_LINKER +NCURSES_EXPORT_VAR(chtype *) +_nc_acs_map(void) +{ + static chtype *the_map = 0; + if (the_map == 0) + the_map = typeCalloc(chtype, ACS_LEN); + return the_map; +} +#else NCURSES_EXPORT_VAR(chtype) acs_map[ACS_LEN] = { 0 }; +#endif NCURSES_EXPORT(void) _nc_init_acs(void) @@ -143,11 +154,11 @@ _nc_init_acs(void) */ if (_nc_tracing & TRACE_CALLS) { size_t n, m; - char show[SIZEOF(acs_map) + 1]; - for (n = 1, m = 0; n < SIZEOF(acs_map); n++) { + char show[ACS_LEN + 1]; + for (n = 1, m = 0; n < ACS_LEN; n++) { if (acs_map[n] != 0) { show[m++] = (char) n; - show[m++] = TextOf(acs_map[n]); + show[m++] = ChCharOf(acs_map[n]); } } show[m] = 0; |