1 Star 0 Fork 16

Xinlong-Chen/glibc

forked from OpenCloudOS Stream/glibc 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
glibc-rh827510.patch 1.00 KB
一键复制 编辑 原始数据 按行查看 历史
abushwang 提交于 2023-07-24 16:45 . update to 2.37
Short description: Fix newlocale error return.
Author(s): Fedora glibc team <[email protected]>
Origin: PATCH
Bug-RHEL: #832516
Bug-Fedora: #827510
Bug-Upstream: #14247
Upstream status: not-submitted
This needs to go upstream right away to fix the error case for
newlocale not correctly returning an error.
2012-06-14 Jeff Law <[email protected]>
* locale/loadlocale.c (_nl_load_locale): Delay setting
file->decided until we have successfully loaded the file's
data.
diff --git a/locale/loadlocale.c b/locale/loadlocale.c
index e3fa187..9fd9216 100644
--- a/locale/loadlocale.c
+++ b/locale/loadlocale.c
@@ -169,7 +169,6 @@ _nl_load_locale (struct loaded_l10nfile *file, int category)
int save_err;
int alloc = ld_mapped;
- file->decided = 1;
file->data = NULL;
fd = __open_nocancel (file->filename, O_RDONLY | O_CLOEXEC);
@@ -278,6 +277,7 @@ _nl_load_locale (struct loaded_l10nfile *file, int category)
newdata->alloc = alloc;
file->data = newdata;
+ file->decided = 1;
}
void
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/xinlong-chen/glibc.git
[email protected]:xinlong-chen/glibc.git
xinlong-chen
glibc
glibc
master

搜索帮助