1 Star 0 Fork 16

Anonymous_Z/tk

forked from src-openEuler/tk 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
Crash-prevention.-Still-buggy-now-test-text-11a.22-f.patch 910 Bytes
一键复制 编辑 原始数据 按行查看 历史
hexiaowen 提交于 2019-09-30 11:18 . Package init
From 87dac59f8407ba5d74e52bf223c1b9509aa679ab Mon Sep 17 00:00:00 2001
From: dgp <dgp@users.sourceforge.net>
Date: Fri, 16 Nov 2018 17:44:47 +0000
Subject: [PATCH 480/693] Crash prevention. Still buggy, now test text-11a.22
fails instead of crashing.
---
generic/tkText.c | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/generic/tkText.c b/generic/tkText.c
index 4c536a22d..a0de1d5d2 100644
--- a/generic/tkText.c
+++ b/generic/tkText.c
@@ -5538,6 +5538,15 @@ RunAfterSyncCmd(
return;
}
+ if (textPtr->afterSyncCmd == NULL) {
+ /*
+ * [Bug 0a9c9151b5] Probably should have idle handlers coded so that
+ * this cannot happen, but a safety check here at least prevents a
+ * crash.
+ */
+ return;
+ }
+
Tcl_Preserve((ClientData) textPtr->interp);
code = Tcl_EvalObjEx(textPtr->interp, textPtr->afterSyncCmd, TCL_EVAL_GLOBAL);
if (code == TCL_ERROR) {
--
2.19.1
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/anonymous_z/tk.git
git@gitee.com:anonymous_z/tk.git
anonymous_z
tk
tk
master

搜索帮助