Loading...
iokit/Kernel/IOInterruptEventSource.cpp xnu-201 xnu-792.6.70
--- xnu/xnu-201/iokit/Kernel/IOInterruptEventSource.cpp
+++ xnu/xnu-792.6.70/iokit/Kernel/IOInterruptEventSource.cpp
@@ -72,9 +72,9 @@
 OSMetaClassDefineReservedUnused(IOInterruptEventSource, 7);
 
 bool IOInterruptEventSource::init(OSObject *inOwner,
-				  Action inAction = 0,
-				  IOService *inProvider = 0,
-				  int inIntIndex = 0)
+				  Action inAction,
+				  IOService *inProvider,
+				  int inIntIndex)
 {
     bool res = true;
 
@@ -97,12 +97,12 @@
 
             autoDisable = (intType == kIOInterruptTypeLevel);
             if (autoDisable) {
-                intHandler = (IOInterruptAction)
-                &IOInterruptEventSource::disableInterruptOccurred;
+                intHandler = OSMemberFunctionCast(IOInterruptAction,
+		    this, &IOInterruptEventSource::disableInterruptOccurred);
             }
             else
-                intHandler = (IOInterruptAction)
-                    &IOInterruptEventSource::normalInterruptOccurred;
+                intHandler = OSMemberFunctionCast(IOInterruptAction,
+		    this, &IOInterruptEventSource::normalInterruptOccurred);
 
             res = (kIOReturnSuccess == inProvider->registerInterrupt
                                         (inIntIndex, this, intHandler));
@@ -123,7 +123,7 @@
     IOInterruptEventSource *me = new IOInterruptEventSource;
 
     if (me && !me->init(inOwner, inAction, inProvider, inIntIndex)) {
-        me->free();
+        me->release();
         return 0;
     }