Re: analyzer: implement five new warnings for misuse of POSIX

2022-07-03 Thread David Malcolm via Gcc
On Sun, 2022-07-03 at 02:46 +, Jay K wrote: >  > check for double "close" of a FD (CWE-1341). >  > check for read/write of a closed file descriptor >   >  These sound good but kinda non general or incomplete to me. >  I mean, isn't the "right" thing, to disallow passing >  a closed fd to "al

Re: analyzer: implement five new warnings for misuse of POSIX

2022-07-02 Thread Jay K via Gcc
 > check for double "close" of a FD (CWE-1341).  > check for read/write of a closed file descriptor    These sound good but kinda non general or incomplete to me.  I mean, isn't the "right" thing, to disallow passing  a closed fd to "almost any" function?    But I realize "almost any" is diffic