summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2015-06-01 18:31:16 (GMT)
committerfvogel <fvogelnew1@free.fr>2015-06-01 18:31:16 (GMT)
commitbe7dbf175563797f831e37d509e71e363b568d06 (patch)
treec1c2739e8e857a1ebebdb6e9bf2368b0ed94d888
parentfb2a611039436e82e09406f4777cc89efc56a1fe (diff)
parent0a4cb74f1cd2e3189d3c59cdcfbc5c0f69ba5761 (diff)
downloadtk-be7dbf175563797f831e37d509e71e363b568d06.zip
tk-be7dbf175563797f831e37d509e71e363b568d06.tar.gz
tk-be7dbf175563797f831e37d509e71e363b568d06.tar.bz2
Fixed bug [2368195fff] - More correct error handling when calling paneconfigure with a non existing window
-rw-r--r--generic/tkPanedWindow.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/generic/tkPanedWindow.c b/generic/tkPanedWindow.c
index c7a1195..82d8611 100644
--- a/generic/tkPanedWindow.c
+++ b/generic/tkPanedWindow.c
@@ -682,6 +682,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,