public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "dmalcolm at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug analyzer/106299] New: RFE: analyzer handling of fdopen Date: Thu, 14 Jul 2022 14:46:56 +0000 [thread overview] Message-ID: <bug-106299-4@http.gcc.gnu.org/bugzilla/> (raw) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106299 Bug ID: 106299 Summary: RFE: analyzer handling of fdopen Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: analyzer Assignee: dmalcolm at gcc dot gnu.org Reporter: dmalcolm at gcc dot gnu.org Blocks: 106003 Target Milestone: --- Now that the analyzer supports checking both filedescriptor *and* FILE * usage, we should probably add special-case handling of fdopen: https://www.man7.org/linux/man-pages/man3/fdopen.3p.html I'm not quite sure how to model the interaction between the two state machines; perhaps a successful fdopen on a fd should transition the fd from an open state to the "stop" state (i.e. stop tracking state on this fd), and transition the FILE * from the start state to the open state. See also bug 101550, which has an example of using fdopen. Referenced Bugs: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106003 [Bug 106003] RFE: -fanalyzer could complain about misuse of file-descriptors
next reply other threads:[~2022-07-14 14:46 UTC|newest] Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-07-14 14:46 dmalcolm at gcc dot gnu.org [this message] 2022-07-14 19:30 ` [Bug analyzer/106299] " egallager at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-106299-4@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).