Issue 634: NSArray exception when getting video info when no camera attached - OSX
BUG = Issue 634 TEST = NONE Review URL: https://webrtc-codereview.appspot.com/859006 git-svn-id: http://webrtc.googlecode.com/svn/trunk@2904 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
parent
f4d2bec3c7
commit
10f5b22610
@ -86,7 +86,7 @@ using namespace webrtc;
|
||||
return [NSNumber numberWithInt:0];
|
||||
}
|
||||
|
||||
if(index > (WebRtc_UWord32)_captureDeviceCountInfo)
|
||||
if(index >= (WebRtc_UWord32)_captureDeviceCountInfo)
|
||||
{
|
||||
return [NSNumber numberWithInt:-1];
|
||||
}
|
||||
@ -179,9 +179,7 @@ using namespace webrtc;
|
||||
inputDevicesWithMediaType:QTMediaTypeVideo]];
|
||||
|
||||
_captureDeviceCountInfo = _captureDevicesInfo.count;
|
||||
if(_captureDeviceCountInfo < 1){
|
||||
return [NSNumber numberWithInt:0];
|
||||
}
|
||||
|
||||
return [NSNumber numberWithInt:0];
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user