Iterate over pixels in image to copy to second image. OpenCV 2.3.1 / 2.2.0 - Invalid Write, Segmentation Fault (Bug #1553)
Description
Hello all,
I'm running OpenCV on Ubuntu Lucid (64) on two AMD64 machines (running two different versions), and both show an identical segfault with the attached file.
gcc version 4.4.3
SSE is enabled, I've also included the cmake cache file for full openCV config.
I'm compiling with:
gcc -std=c++0x -ggdb pkg-config --cflags opencv
pkg-config --libs
-o debug debug.cpp
opencv
gdb says copyPercep() is causing a segmentation fault. Valgrind sees an invalid write in copyPercep().
I've been over this code for a week and I don't see what I'm doing wrong.
Is this a bug? Or am I doing something wrong?
B. Bogart
Associated revisions
Merge pull request #1553 from pablospe:doc_include_directories_cmake
History
Updated by b b about 13 years ago
The problem was my assumption that at() would have internal bounds checking, which it clearly does not. If you don't write outside of the Mat, it will not crash.
- Status changed from Open to Done
- (deleted custom field) set to invalid
Updated by Andrey Kamaev about 13 years ago
- Status changed from Done to Cancelled
Updated by Andrey Kamaev almost 13 years ago
- Target version set to 2.4.0