See https://github.com/google/sanitizers/issues/1253.
Small patch to enable compilation on (ancient) Red Hat Enterprise Linux 5.
Differential D80648
Avoid O_CLOEXEC to allow building on older Linux (RHEL5) plopresti on May 27 2020, 10:26 AM. Authored by
Details See https://github.com/google/sanitizers/issues/1253. Small patch to enable compilation on (ancient) Red Hat Enterprise Linux 5.
Diff Detail
Event TimelineComment Actions Vitaly, please review (and land if ok). We don't call fcntl() anywhere else in the sanitizer run-time.
Comment Actions Tried to keep this clean and to avoid duplicating code on the #if - #else path. Let me know if you see a better way to do it...
|
I guess idea was to avoid leaking fd as results of data race.
We use this function from random places, so race is quite possible.
Probably this the leak is not very critical however I'd prefer to we use O_CLOEXEC where possible.
Could you update the patch to use fcntl only when O_CLOEXEC is not available?