Skip to content

Commit

Permalink
KernelTests: Update tests for dataqueue usage changes
Browse files Browse the repository at this point in the history
  • Loading branch information
russellhancox committed May 18, 2015
1 parent 536b896 commit d5c1d66
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Tests/KernelTests/main.m
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ - (void)beginListening {

/// Begin listening for events
queueMemory = (IODataQueueMemory *)address;
while (IODataQueueWaitForAvailableData(queueMemory, receivePort) == kIOReturnSuccess) {
do {
while (IODataQueueDataAvailable(queueMemory)) {
dataSize = sizeof(vdata);
kr = IODataQueueDequeue(queueMemory, &vdata, &dataSize);
Expand Down Expand Up @@ -227,7 +227,7 @@ - (void)beginListening {
TFAILINFO("Error receiving data: %d", kr);
}
}
}
} while (IODataQueueWaitForAvailableData(queueMemory, receivePort) == kIOReturnSuccess);

IOConnectUnmapMemory(self.connection, kIODefaultMemoryType, mach_task_self(), address);
mach_port_destroy(mach_task_self(), receivePort);
Expand Down

0 comments on commit d5c1d66

Please sign in to comment.