--- a/dom/camera/DOMCameraControl.cpp
+++ b/dom/camera/DOMCameraControl.cpp
@@ -306,17 +306,21 @@ nsDOMCameraControl::nsDOMCameraControl(u
// Start the camera...
if (haveInitialConfig) {
rv = mCameraControl->Start(&config);
} else {
rv = mCameraControl->Start();
}
#ifdef MOZ_WIDGET_GONK
} else {
- rv = mCameraControl->SetConfiguration(config);
+ if (haveInitialConfig) {
+ rv = mCameraControl->SetConfiguration(config);
+ } else {
+ rv = NS_OK;
+ }
}
#endif
if (NS_FAILED(rv)) {
mListener->OnUserError(DOMCameraControlListener::kInStartCamera, rv);
}
}
nsDOMCameraControl::~nsDOMCameraControl()