[webkit-dev] showTree crashes in gdb
Benjamin Kalman
kalman at chromium.org
Sun Mar 20 21:00:59 PDT 2011
Hi
I've noticed ever since working with DOM and editing code that showTree
often doesn't work. As in, it segfaults from gdb (or prints Chinese
characters rather than a DOM). It seems to be especially bad recently;
though this might just reflect my gradually diminishing patience.
I had a brief look myself and came away with observations:
- It only happens from gdb's command line. Compiling in a call to
showTree(foo) works, while breaking on that line and running "call
showTree(foo)" from gdb crashes.
- The segfault trace is different every time, but is usually in RefPtr
code.
- Sometimes "call showTree(foo)" will work, but calling it again will
crash.
- Stepping through showTree in gdb, IIRC the segfault happens right after
stepping out of one of the methods. I can't remember which one, nor whether
it was predictably the same method.
Hesitant conclusion: there is a bug in gdb tickled by something in RefPtr,
perhaps the funky operator overriding behaviour, but my C++ isn't good
enough to fully understand why this might happen.
Has anybody else looked into this before? It would be really really
convenient to be able to rely on showTree.
-- Ben
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20110321/49a2f86e/attachment.html>
More information about the webkit-dev
mailing list