mvp: fixed default device detection
The check "open()!=0" is wrong, you have to write "open()>=0", because -1 means error, and 0 is a valid file handle.
This commit is contained in:
@@ -114,7 +114,7 @@ mvp_output_test_default_device(void)
|
||||
|
||||
fd = open("/dev/adec_pcm", O_WRONLY);
|
||||
|
||||
if (fd) {
|
||||
if (fd >= 0) {
|
||||
close(fd);
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user