[Uml-devel] [ uml-Bugs-671735 ] SIGSEGV on printing (fwd)
Sebastian Stein
seb_stein at gmx.de
Tue Jan 21 13:07:04 UTC 2003
Jonathan Riddell <jr at jriddell.org> [030121 18:52]:
> Foo. This is quite significant and might warrant a 1.1.1 release on it's
> own.
We should wait some days to see what other bugs come up. Then we could
release a bug fix release!
> Unfortunatly I'm completely stuck on it. The seg fault seems to be on
> pViewList in UMLDoc's findView() but I've no idea why it should suddenly
> segfault then since that method and pViewList are used previously without
> any problems.
You looked in the wrong place. Of course findView is correct, because it is
called so often and never failed. In such a case you have to find out which
parameter might be wrong and why. So you have to find the caller and than
play around.
I found out that in m_pIdList[0] has a value of 101 was. I don't know how
these values are added to the different diagrams, but it looked a little bit
bad. So I searched around, when this value is set. It is done in the
constructor. But there doesn't seem to be an error. So I had to check, why
((UMLView*)m_pDoc->getCurrentView())->getID(); returns such a crazy value.
Well, so you have to check if m_pDoc is ok. Well, I scrolled a little bit up
and there I saw the line, which was wrong:
m_pDoc = m_pDoc;
I think it should be: this->m_pDoc = m_pDoc; But it is better to do this
directly in the constructor:
class::constructor(..., pointer_type * pointer):m_pointer(pointer)
Now it would be interesting to know, if there are other places in the code
where such a thing was done! Does anybody know how to grep for it?
Steinchen
--
Umbrello UML Modeller
Description : UML diagram drawing tool for KDE with code generation
Homepage : http://www.umbrello.org/
Bug report : http://sourceforge.net/tracker/?group_id=24919&atid=382951
Feature request : http://sourceforge.net/tracker/?group_id=24919&atid=382954
More information about the umbrello-devel
mailing list