diff --git a/src/detection/battery/battery_apple.c b/src/detection/battery/battery_apple.c index f3d98c071..3af71bf56 100644 --- a/src/detection/battery/battery_apple.c +++ b/src/detection/battery/battery_apple.c @@ -13,7 +13,7 @@ const char* ffDetectBatteryImpl(FFinstance* instance, FFlist* results) return "IOServiceMatching(\"AppleSmartBattery\") failed"; io_iterator_t iterator; - if(IOServiceGetMatchingServices(0, matchDict, &iterator) != kIOReturnSuccess) + if(IOServiceGetMatchingServices(MACH_PORT_NULL, matchDict, &iterator) != kIOReturnSuccess) return "IOServiceGetMatchingServices() failed"; io_registry_entry_t registryEntry; diff --git a/src/detection/gpu/gpu_apple.c b/src/detection/gpu/gpu_apple.c index e7e58116b..745704457 100644 --- a/src/detection/gpu/gpu_apple.c +++ b/src/detection/gpu/gpu_apple.c @@ -11,7 +11,7 @@ const char* ffDetectGPUImpl(FFlist* gpus, const FFinstance* instance) CFMutableDictionaryRef matchDict = IOServiceMatching(kIOAcceleratorClassName); io_iterator_t iterator; - if(IOServiceGetMatchingServices(0, matchDict, &iterator) != kIOReturnSuccess) + if(IOServiceGetMatchingServices(MACH_PORT_NULL, matchDict, &iterator) != kIOReturnSuccess) return "IOServiceGetMatchingServices() failed"; io_registry_entry_t registryEntry;