| 132 | } |
| 133 | |
| 134 | int NodeDriver::DestroyDevice(void) |
| 135 | { |
| 136 | int dev_num = GetDeviceNum(); |
| 137 | int count = 0; |
| 138 | |
| 139 | for(int i = 0; i < dev_num; i++) |
| 140 | { |
| 141 | Device* dev = GetDevice(0); |
| 142 | |
| 143 | if(DestroyDevice(dev)) |
| 144 | count++; |
| 145 | else |
| 146 | break; |
| 147 | } |
| 148 | |
| 149 | return count; |
| 150 | } |
| 151 | |
| 152 | int NodeDriver::GetDeviceNum(void) |
| 153 | { |