PoshSylvester / cvblob

Automatically exported from code.google.com/p/cvblob
GNU Lesser General Public License v3.0
0 stars 0 forks source link

cvb::cvReleaseBlobs(blobs); cause to crash when using -std=c++0x for project #31

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Create blobs:
    cvb::CvBlobs blobs;
    cvb::CvTracks tracks;

    unsigned int result = cvLabel(&img, labelImg, blobs);
    ...
2. Delete blobs:
    cvb::cvReleaseBlobs(blobs);

Error:

#0 0x404b10 std::_List_base<unsigned char, std::allocator<unsigned char> 
>::_M_clear(this=0x49) 
(/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../include/c++/4.7.0/bits/
list.tcc:70)
#1 0x4045b4 std::_List_base<unsigned char, std::allocator<unsigned char> 
>::~_List_base(this=0x49, __in_chrg=<optimized out>) 
(/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../include/c++/4.7.0/bits/
stl_list.h:401)
#2 0x404278 std::list<unsigned char, std::allocator<unsigned char> 
>::~list(this=0x49, __in_chrg=<optimized out>) 
(/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.0/../../../../include/c++/4.7.0/bits/
stl_list.h:458)
#3 0x404296 cvb::CvContourChainCode::~CvContourChainCode(this=0x41, 
__in_chrg=<optimized out>) (/usr/include/cvblob.h:111)
#4 0x40433f cvb::cvReleaseBlob(blob=0x6232f0) (/usr/include/cvblob.h:312)
#5 0x4043e8 cvb::cvReleaseBlobs(blobs=std::map with 56 elements) 
(/usr/include/cvblob.h:328)
#6 0x403bc8 BlobDetect(frameGray=..., inFrame=...) 
(/home/revx/projects/SoccerCMK/balldetector.cpp:56)
#7 0x403cf4 BallDetector::detectBall(this=0x613800, frame=...) 
(/home/revx/projects/SoccerCMK/balldetector.cpp:66)
#8 0x40917f main(argc=1, argv=0x7fffffffe7b8) 
(/home/revx/projects/SoccerCMK/main.cpp:230)

tested on ArchLinux x64. Kernel 3.3.7
GCC 4.7.0

Original issue reported on code.google.com by doomr...@gmail.com on 29 May 2012 at 1:38

GoogleCodeExporter commented 8 years ago
Fixed by recompiling cvblob with -std=c++0x flag

Original comment by doomr...@gmail.com on 29 May 2012 at 1:42