rorth wrote:

It took me a bit to notice this snippet in `sanitizer_solaris.cpp`:
```
DECLARE__REAL_AND_INTERNAL(int, fork, void) {
  // TODO(glider): this may call user's pthread_atfork() handlers which is bad.
  return _REAL(fork)();
}
```
which didn't show up in searches for `internal_fork`.

>From what I could learn from `libc` disassembly and the OpenSolaris sources, 
>the only way to avoid the handlers on Solaris is to invoke the syscall 
>directly.  This is highly unportable, however: syscalls are an implemention 
>detail that can (and **does**) change.  There's reasonable hope that this 
>won't happen for the remaining livetime of Solaris 11.4, though.

I'll give such a patch a try...

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

Reply via email to