Sirraide wrote:

> What do actual libc implementations do when they are passed a nullptr? Do any 
> of them define their behaviour?

Glibc at least checks for null and returns `-1`; I haven’t been able to check 
other libc implementations. I also tried looking at the C standard, but from 
what I can tell it doesn’t talk about this situation at all, though maybe I 
missed something

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

Reply via email to