diff --git a/modules/photo/src/align.cpp b/modules/photo/src/align.cpp index cfb8a5d84b..d83bf69d92 100644 --- a/modules/photo/src/align.cpp +++ b/modules/photo/src/align.cpp @@ -123,7 +123,7 @@ public: Mat img0 = _img0.getMat(); Mat img1 = _img1.getMat(); CV_Assert(img0.channels() == 1 && img0.type() == img1.type()); - CV_Assert(img0.size() == img0.size()); + CV_Assert(img0.size() == img1.size()); int maxlevel = static_cast(log((double)max(img0.rows, img0.cols)) / log(2.0)) - 1; maxlevel = min(maxlevel, max_bits - 1);