[bind10-dev] Bugs identified by STL debug mode (Re: Windows support)

JINMEI Tatuya / 神明達哉 jinmei at isc.org
Fri Apr 8 22:28:27 UTC 2011


At Wed, 06 Apr 2011 11:54:24 +0000,
Francis Dupont <fdupont at isc.org> wrote:

>  - I found some C++ bugs or very questionable stuff, for instance
>   &v[0] where v is the empty vector is IMHO a bug
> 
>  - the Debug version fails with "string iterator not dereferencable",
>   I believe operator*() invoked in functor madness doesn't play nice
>   with xxx.end()...
> 
> I'll open tickets for C++ bugs or workaround with choices, and save
> the current work.

Thanks, and this reminded me that we used stlport (with SunStudio C++
compiler) for our Solaris buildbot, which also has a debug mode.  I
managed to make the code buildable with that mode, and it reported at
least the following bugs:

[ RUN      ] Rdata_Unknown_Test.createFromText
/export/home/opt/sunstudio12.1/prod/include/CC/stlport4/stl/debug/_vector.h(129): STL error : Index out of bounds
/export/home/opt/sunstudio12.1/prod/include/CC/stlport4/stl/debug/_vector.h(129): STL assertion failure:     __n < _Base::size()

[ RUN      ] CCSessionTest.checkCommand
/export/home/opt/sunstudio12.1/prod/include/CC/stlport4/stl/debug/_vector.h(250): STL error : Past-the-end iterator could not be erased
/export/home/opt/sunstudio12.1/prod/include/CC/stlport4/stl/debug/_vector.h(250): STL assertion failure:     __position._M_iterator !=this->_M_finish

[ RUN      ] ResponseScrubberTest.ScrubAllSectionsValid
/export/home/opt/sunstudio12.1/prod/include/CC/stlport4/stl/debug/_iterator.h(157): STL assertion failure : _Incrementable(*this,1,_Iterator_category())

Since these errors made the test process abort itself, it cannot
report other errors in the same module.  But we can at least be
confident that all other modules than these three are bug free in
terms of stlport checks.  I think the current quality is not so bad.

---
JINMEI, Tatuya



More information about the bind10-dev mailing list