I have a segmentation fault in line 66 of GroupResult.h and I can't
figure out why that causes any problem, I appreciate if anyone can
help.
line 66 of Result.h:
66 size_t size() const { return _bdl.size(); }
where _bdl is a private attribute of
class Result
{
private:
int _type;
vector<BlockData*> _bdl;
};
I step thru the debugger, _bdl is not null. So I can't understand why
calling '_bdl.size()' returns a Segmentation fault.
Any help is appreciated.
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1208583648 (LWP 9292)]
0x03edeffb in std::vector<BlockData*, std::allocator<BlockData*>
::begin (this=0x9) at /usr/lib/gcc/i386-redhat-linux/4.0.2/../../../../include/c++/4.0.2/bits/stl_vector.h:343 /usr/include/c++/4.0.2/bits/stl_vector.h:343:12255:beg:0x3edeffb
(gdb) bt
#0 0x03edeffb in std::vector<BlockData*, std::allocator<BlockData*>::begin (this=0x9) at /usr/lib/gcc/i386-redhat-linux/4.0.2/../../../../include/c++/4.0.2/bits/stl_vector.h:343 #1 0x03edf08d in std::vector<BlockData*, std::allocator<BlockData*>::size (this=0x9) at /usr/lib/gcc/i386-redhat-linux/4.0.2/../../../../include/c++/4.0.2/bits/stl_vector.h:403
#2 0x03edf0ca in GroupResult::size (this=0x1) at Result.h:66
#3 0x03f11e98 in PageBreaker::handleOverLap (this=0xbf97a63c) at
PageBreaker.cpp:274