this repo has no description
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

[kernel/libsyscall] Add back fallback for mach_get_times

Fixes notifyd crashing

Thomas A 58fba5a7 272dbd27

+9
+9
src/kernel/libsyscall/wrappers/mach_get_times.c
··· 64 64 if (__gettimeofday_with_mach(&tv, NULL, &tbr) < 0) { 65 65 return KERN_FAILURE; 66 66 } else if (tbr == 0) { 67 + #ifdef DARLING 68 + // In the past, Apple had a fallback solution if the tbr is still 0. However, 69 + // they removed this in their recent code. In the long run, it might be a good 70 + // idea to figure out why tbr returns 0 for notifyd. 71 + 72 + // Apple's Comment: On an old kernel, likely chroot'ed. (remove next year) 73 + tbr = mach_absolute_time(); 74 + #else 67 75 __builtin_trap(); 76 + #endif 68 77 } 69 78 } 70 79