[clang] [analyzer] Fix crash of StreamChecker when eval calling 'fopen' (PR #100990)

DonĂ¡t Nagy via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 29 02:35:27 PDT 2024


================
@@ -1703,7 +1703,11 @@ are detected:
 * Invalid 3rd ("``whence``") argument to ``fseek``.
 
 The stream operations are by this checker usually split into two cases, a success
-and a failure case. However, in the case of write operations (like ``fwrite``,
+and a failure case.
+On the success case it also assumes that the current value of ``stdout``,
+``stderr``, or ``stdin`` can't be equal to the file pointer returned by ``fopen``.
+
+In the case of write operations (like ``fwrite``,
----------------
NagyDonat wrote:

Personally I'd re-wrap the lines; but I can accept this if you think that it's important to minimize the diff footprint.

https://github.com/llvm/llvm-project/pull/100990


More information about the cfe-commits mailing list