X-Git-Url: https://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=ncurses%2Ftinfo%2Fhome_terminfo.c;h=ce6576a82f822358181f5de679fb3d1e13f7185f;hp=ad2f5f6e5bcdceee653a82595ada3aa726580e9a;hb=614ef82f41eda084798068d715ef91b072014ca9;hpb=46722468f47c2b77b3987729b4bcf2321cccfd01 diff --git a/ncurses/tinfo/home_terminfo.c b/ncurses/tinfo/home_terminfo.c index ad2f5f6e..ce6576a8 100644 --- a/ncurses/tinfo/home_terminfo.c +++ b/ncurses/tinfo/home_terminfo.c @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (c) 1998-2000,2002 Free Software Foundation, Inc. * + * Copyright (c) 1998-2004,2005 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 * @@ -27,7 +27,7 @@ ****************************************************************************/ /**************************************************************************** - * Author: Thomas E. Dickey 1998,2000 * + * Author: Thomas E. Dickey 1998,2000,2004,2005 * ****************************************************************************/ /* @@ -37,7 +37,7 @@ #include #include -MODULE_ID("$Id: home_terminfo.c,v 1.7 2002/09/07 20:04:51 tom Exp $") +MODULE_ID("$Id: home_terminfo.c,v 1.9 2005/07/02 19:43:38 tom Exp $") #define my_length (strlen(home) + sizeof(PRIVATE_INFO)) @@ -46,6 +46,8 @@ MODULE_ID("$Id: home_terminfo.c,v 1.7 2002/09/07 20:04:51 tom Exp $") NCURSES_EXPORT(char *) _nc_home_terminfo(void) { + char *result = 0; +#ifdef USE_HOME_TERMINFO char *home; static char *temp = 0; @@ -59,7 +61,8 @@ _nc_home_terminfo(void) (void) sprintf(temp, PRIVATE_INFO, home); } } - return temp; + result = temp; } - return 0; +#endif + return result; }