提交 ddc947ed 编写于 作者: R Rich Felker

fix missing flush of stderr at exit if it was put in buffered mode

commit 0b80a7b0 added the ability to
set application-provided stdio FILE buffers, adding the possibility
that stderr might be buffered at exit time, but __stdio_exit did not
have code to flush it.

this regression was not present in any release.
上级 35cd7c09
...@@ -19,6 +19,7 @@ void __stdio_exit(void) ...@@ -19,6 +19,7 @@ void __stdio_exit(void)
for (f=*__ofl_lock(); f; f=f->next) close_file(f); for (f=*__ofl_lock(); f; f=f->next) close_file(f);
close_file(__stdin_used); close_file(__stdin_used);
close_file(__stdout_used); close_file(__stdout_used);
close_file(__stderr_used);
} }
weak_alias(__stdio_exit, __stdio_exit_needed); weak_alias(__stdio_exit, __stdio_exit_needed);
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册