7 |
|
* |
8 |
|
* Based on Apple's CDROMSample.c and Evan Jones' cd-discid.c patches |
9 |
|
* |
10 |
< |
* Basilisk II (C) 1997-2005 Christian Bauer |
10 |
> |
* Basilisk II (C) 1997-2008 Christian Bauer |
11 |
|
* |
12 |
|
* This program is free software; you can redistribute it and/or modify |
13 |
|
* it under the terms of the GNU General Public License as published by |
115 |
|
static void media_arrived(int type, io_iterator_t iterator) |
116 |
|
{ |
117 |
|
io_object_t obj; |
118 |
< |
while ((obj = IOIteratorNext(iterator)) != NULL) { |
118 |
> |
while ((obj = IOIteratorNext(iterator))) { |
119 |
|
char path[MAXPATHLEN]; |
120 |
|
kern_return_t kernResult = get_device_path(obj, path, sizeof(path)); |
121 |
|
if (kernResult == KERN_SUCCESS) { |
137 |
|
static void media_removed(int type, io_iterator_t iterator) |
138 |
|
{ |
139 |
|
io_object_t obj; |
140 |
< |
while ((obj = IOIteratorNext(iterator)) != NULL) { |
140 |
> |
while ((obj = IOIteratorNext(iterator))) { |
141 |
|
char path[MAXPATHLEN]; |
142 |
|
kern_return_t kernResult = get_device_path(obj, path, sizeof(path)); |
143 |
|
if (kernResult == KERN_SUCCESS) { |