This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug stdio/21393] New: Missing dup3 error check in freopen, freopen64
- From: "fweimer at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Mon, 17 Apr 2017 20:10:52 +0000
- Subject: [Bug stdio/21393] New: Missing dup3 error check in freopen, freopen64
- Auto-submitted: auto-generated
https://sourceware.org/bugzilla/show_bug.cgi?id=21393
Bug ID: 21393
Summary: Missing dup3 error check in freopen, freopen64
Product: glibc
Version: 2.25
Status: NEW
Severity: normal
Priority: P2
Component: stdio
Assignee: unassigned at sourceware dot org
Reporter: fweimer at redhat dot com
Target Milestone: ---
The code has this:
__dup3 (_IO_fileno (result), fd,
(result->_flags2 & _IO_FLAGS2_CLOEXEC) != 0
? O_CLOEXEC : 0);
That is, there is no error checking for dup3 failure. We should add error
checking here.
--
You are receiving this mail because:
You are on the CC list for the bug.