diff options
Diffstat (limited to 'contrib/ncurses/panel/p_replace.c')
-rw-r--r-- | contrib/ncurses/panel/p_replace.c | 27 |
1 files changed, 15 insertions, 12 deletions
diff --git a/contrib/ncurses/panel/p_replace.c b/contrib/ncurses/panel/p_replace.c index a3b88cbfa88e..5d0d295c8b17 100644 --- a/contrib/ncurses/panel/p_replace.c +++ b/contrib/ncurses/panel/p_replace.c @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (c) 1998,2000 Free Software Foundation, Inc. * + * Copyright (c) 1998-2000,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 * @@ -36,20 +36,23 @@ */ #include "panel.priv.h" -MODULE_ID("$Id: p_replace.c,v 1.7 2001/02/24 23:41:38 tom Exp $") +MODULE_ID("$Id: p_replace.c,v 1.9 2005/02/19 16:41:31 tom Exp $") NCURSES_EXPORT(int) -replace_panel (PANEL *pan, WINDOW *win) +replace_panel(PANEL * pan, WINDOW *win) { - if(!pan) - return(ERR); - - if (IS_LINKED(pan)) { - Touchpan(pan); - PANEL_UPDATE(pan,(PANEL*)0); - } - + T((T_CALLED("replace_panel(%p,%p)"), pan, win)); + + if (!pan) + returnCode(ERR); + + if (IS_LINKED(pan)) + { + Touchpan(pan); + PANEL_UPDATE(pan, (PANEL *) 0); + } + pan->win = win; - return(OK); + returnCode(OK); } |