DonatNagyE wrote:

This [report from 
vim](https://codechecker-demo.eastus.cloudapp.azure.com/Default/report-detail?run=vim_v8.2.1920_errno_alpha_unix&newcheck=vim_v8.2.1920_errno_unix&is-unique=on&diff-type=New&report-id=3214372&report-hash=9582050be3f26e8ebf9dcf4c5b0f82b3&report-filepath=%2amemline.c)
 seems to be a false positive:

![image](https://github.com/llvm/llvm-project/assets/43410265/14bfd4b2-686b-452c-b417-465cdb43f11b)

Readlink returns either -1 (failure, errno is set) or the number of characters 
read from the symlink entry (i.e. the filename the symlink points to). I don't 
think that it's possible to create a "symlink to emptystring", so the the 
checkers should recognize that if the return value is `<= 0`, then it's a 
failure.


https://github.com/llvm/llvm-project/pull/69469
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to