summaryrefslogtreecommitdiff
path: root/panel/p_replace.c
diff options
context:
space:
mode:
authorXin LI <delphij@FreeBSD.org>2014-02-28 19:12:44 +0000
committerXin LI <delphij@FreeBSD.org>2014-02-28 19:12:44 +0000
commit4b819fa20a8d007a10f2d3e8d6a5dedf7f18fc9a (patch)
treeb8f6e12b479a78216f3bffb8e1258d54087268de /panel/p_replace.c
parente07762606a5bf651a501cb095c98cba90e4a8fe2 (diff)
Notes
Diffstat (limited to 'panel/p_replace.c')
-rw-r--r--panel/p_replace.c26
1 files changed, 12 insertions, 14 deletions
diff --git a/panel/p_replace.c b/panel/p_replace.c
index d3733ed22e2f..5d0d295c8b17 100644
--- a/panel/p_replace.c
+++ b/panel/p_replace.c
@@ -1,5 +1,5 @@
/****************************************************************************
- * Copyright (c) 1998-2005,2010 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,25 +36,23 @@
*/
#include "panel.priv.h"
-MODULE_ID("$Id: p_replace.c,v 1.11 2010/01/23 21:22:16 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)
{
- int rc = ERR;
+ T((T_CALLED("replace_panel(%p,%p)"), pan, win));
- T((T_CALLED("replace_panel(%p,%p)"), (void *)pan, (void *)win));
+ if (!pan)
+ returnCode(ERR);
- if (pan)
+ if (IS_LINKED(pan))
{
- GetHook(pan);
- if (IS_LINKED(pan))
- {
- Touchpan(pan);
- PANEL_UPDATE(pan, (PANEL *) 0);
- }
- pan->win = win;
- rc = OK;
+ Touchpan(pan);
+ PANEL_UPDATE(pan, (PANEL *) 0);
}
- returnCode(rc);
+
+ pan->win = win;
+
+ returnCode(OK);
}