sipp icon indicating copy to clipboard operation
sipp copied to clipboard

Restrict overmatching MACH ifdef to only trigger on OSX and Mach

Open Zopolis4 opened this issue 3 years ago • 0 comments

As said on line 60, this check is only intended for OSX.

// OS X does not have clock_gettime, use clock_get_time

Hurd also uses Mach, but does not have the same shortcomings as OSX in this area. https://www.gnu.org/software/hurd/hurd/porting/guidelines.html

#ifdef __MACH__
Some applications put Apple Darwin-specific code inside #ifdef __MACH__ guards. Such guard is clearly not enough, since not only Apple uses Mach as a kernel. This should be replaced by #if defined(__MACH__) && defined(__APPLE__)

Zopolis4 avatar Sep 21 '22 23:09 Zopolis4