Philbert: A CFRetain isn't needed for the dictionary returned by IOServiceMatching. IOServiceMatching returns a retained dictionary that requires a CFRelease. Passing that dictionary into IOServiceGetMatchingServices consumes the retain. Since the match_dictionary is not used after the call to IOServiceGetMatchingServices, I can skip an extra retain/release on that object.

You are right about the IOObjectRelease on the entry_iterator and serviceObject though. I'll fix the code above to reflect that. Thanks!