diff options
author | fvogel <fvogelnew1@free.fr> | 2015-05-24 23:11:56 (GMT) |
---|---|---|
committer | fvogel <fvogelnew1@free.fr> | 2015-05-24 23:11:56 (GMT) |
commit | c61c12b4b2317fbb1cd2fbc294078d661c2a333c (patch) | |
tree | 5deae2fa1d75180f313b46dacd8b68c8516a26f3 | |
parent | d1c48d32205766e74234558200f846f04f04c2ae (diff) | |
download | tk-c61c12b4b2317fbb1cd2fbc294078d661c2a333c.zip tk-c61c12b4b2317fbb1cd2fbc294078d661c2a333c.tar.gz tk-c61c12b4b2317fbb1cd2fbc294078d661c2a333c.tar.bz2 |
More correct error handling when calling paneconfigure with a non existing windowbug_2368195fff
-rw-r--r-- | generic/tkPanedWindow.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/generic/tkPanedWindow.c b/generic/tkPanedWindow.c index 3ae473a..c79be25 100644 --- a/generic/tkPanedWindow.c +++ b/generic/tkPanedWindow.c @@ -678,6 +678,15 @@ PanedWindowWidgetObjCmd( if (objc <= 4) { tkwin = Tk_NameToWindow(interp, Tcl_GetString(objv[2]), pwPtr->tkwin); + if (tkwin == NULL) { + /* + * Just a plain old bad window; Tk_NameToWindow filled in an + * error message for us. + */ + + result = TCL_ERROR; + break; + } for (i = 0; i < pwPtr->numSlaves; i++) { if (pwPtr->slaves[i]->tkwin == tkwin) { resultObj = Tk_GetOptionInfo(interp, |