opencv-2.4.6.1/build/modules/imgproc/precomp.hpp:69: possible bad assert ? (Bug #3346)
Description
I just compiled opencv with gcc flag -Wlogical-op
It said
opencv-2.4.6.1/build/modules/imgproc/precomp.hpp:69:49: warning: logical 'or' of collectively exhaustive tests is always true [-Wlogical-op]
Source code is
#define CV_FAST_CAST_8U(t) (assert(-256 <= (t) || (t) <= 512), icvSaturate8u_cv[(t)+256])
Suggest swap || for &&.
I checked your latest sources and the bug also seems to exist there.
Associated revisions
Fixed bug in report #3346
Merge pull request #3346 from Nerei:fixed_memory_leak_in_viz
History
Updated by Dmitry Retinskiy over 11 years ago
Hi David,
thanks for the ticket.
We would appreciate if you could create a pull request to speed up review and fix of the problem.
Thanks.
- Status changed from New to Open
- Target version changed from 2.4.7 to 2.4.8
Updated by Dinar Ahmatnurov over 11 years ago
- Category set to build/install
Updated by Steven Puttemans over 11 years ago
Pull request for path added. Will keep you guys up to date of the result.
https://github.com/Itseez/opencv/pull/1843
- % Done changed from 0 to 50
Updated by Steven Puttemans over 11 years ago
https://github.com/Itseez/opencv/pull/1853
New pull request rebased to 2.4 since it should be applied there.
Updated by Steven Puttemans over 11 years ago
- Status changed from Open to Done
- % Done changed from 50 to 100