diff --git a/modules/highgui/src/cap_dc1394_v2.cpp b/modules/highgui/src/cap_dc1394_v2.cpp index a88d9ca4297d879ade7dae17424a977ecb473bd4..81b2916257a91daa3d2af4875885bbe5d72572af 100644 --- a/modules/highgui/src/cap_dc1394_v2.cpp +++ b/modules/highgui/src/cap_dc1394_v2.cpp @@ -795,9 +795,9 @@ bool CvCaptureCAM_DC1394_v2_CPP::setProperty(int propId, double value) //first: check boundaries if (value < act_feature->min) { - value = act_feature->min; - } - else if (value > act_feature->max) + value = act_feature->min; + } + else if (value > act_feature->max) { value = act_feature->max; } @@ -806,7 +806,8 @@ bool CvCaptureCAM_DC1394_v2_CPP::setProperty(int propId, double value) { act_feature->value = value; return true; - } + } + } return false; } return true;