Bug found (and fixed) in locating devices
Status: Alpha
Brought to you by:
svdbeek
I found a bug in the source file that was causing it to always report that the found device was not available. I fixed it by changing the following lines:
if ( i == foundDevices ) {
//searched to end of list without result
fprintf(stderr, "Device %d is not available.\n", deviceID);
exit(EX_UNAVAILABLE); /* error */
}
To:
if ( i > foundDevices ) {
//searched to end of list without result
fprintf(stderr, "Device %d is not available.\n", deviceID);
exit(EX_UNAVAILABLE); /* error */
}
Once I made this change and recompiled, it works great.
Good work, btw.