14 Star 0 Fork 20

src-openEuler/autogen

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
backport-fix-stray-blanking-of-config-file-char.patch 1.13 KB
一键复制 编辑 原始数据 按行查看 历史
From 3b33eb2fc09a2d7221da6bc7159f374fdef8906a Mon Sep 17 00:00:00 2001
From: Bruce Korb <[email protected]>
Date: Fri, 6 Sep 2019 08:28:00 -0700
Subject: [PATCH] fix stray blanking of config file char
* autoopts/configfile.c (trim_xml_text): remove unnecessary and
occasionally destructive blanking of first character.
---
autoopts/configfile.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/autoopts/configfile.c b/autoopts/configfile.c
index 783a9d8a..e8f557ad 100644
--- a/autoopts/configfile.c
+++ b/autoopts/configfile.c
@@ -802,10 +802,9 @@ trim_xml_text(char * intxt, char const * pznm, tOptionLoadMode mode)
pz[1] = '/';
memcpy(pz+2, pznm, nm_len);
nm_len += 2;
- pz[nm_len++] = '>';
+ pz[nm_len++] = '>'; // nm_len is now length of end mark
pz[nm_len] = NUL;
- *intxt = ' ';
etext = strstr(intxt, pz);
if (pz != z) AGFREE(pz);
}
@@ -825,6 +824,7 @@ trim_xml_text(char * intxt, char const * pznm, tOptionLoadMode mode)
}
/**
+ * process hex and amphersand encoded characters.
*/
static void
cook_xml_text(char * pzData)
--
2.27.0
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/src-openeuler/autogen.git
[email protected]:src-openeuler/autogen.git
src-openeuler
autogen
autogen
master

搜索帮助