[PATCH] Make the analyzer detect more misues of open(2)

Daniel Fahlgren daniel at fahlgren.se
Mon Aug 18 05:14:53 PDT 2014


Hi,

These patches makes the unix.API checker detect more errors when using
open(2). The first is to detect when open is called with more than three
arguments. The second patch makes sure that the third argument is an
integer.

I've added a new test file for these cases. The current one, nix-fns.c,
does a lot more than simply testing the expected warnings.

Cheers,
Daniel Fahlgren
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Warn-when-open-is-called-with-too-many-arguments.patch
Type: text/x-patch
Size: 4302 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20140818/acbc6b49/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-Check-if-open-2-is-called-with-a-valid-mode.patch
Type: text/x-patch
Size: 2772 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20140818/acbc6b49/attachment-0001.bin>


More information about the cfe-commits mailing list