After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 136625 - assertion fails (parent_style != NULL) followed by a crash
assertion fails (parent_style != NULL) followed by a crash
Status: RESOLVED INCOMPLETE
Product: gtkhtml2
Classification: Deprecated
Component: General
2.4.x
Other Linux
: Normal major
: ---
Assigned To: Rodney Dawes
Rodney Dawes
: 138400 140962 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2004-03-09 10:45 UTC by Sven Neumann
Modified: 2008-11-16 17:56 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
HTML file that crashes the renderer (9.83 KB, text/html)
2004-03-09 10:46 UTC, Sven Neumann
Details
stylesheet used (1.30 KB, text/plain)
2004-03-09 10:48 UTC, Sven Neumann
Details
a more uptodate page from gimp-help-2 which reliably triggers this problem (11.37 KB, text/html)
2004-10-28 15:00 UTC, Sven Neumann
Details

Description Sven Neumann 2004-03-09 10:45:17 UTC
The GIMP-2.0 help-browser which is based on libgtkhtml2 crashes quite
frequently when loading GIMP help pages. Every time the console output
looks similar:

HtmlDocument-ERROR **: file htmldocument.c: line 239 
(html_document_node_inserted_traverser): assertion failed: (parent_style !=
NULL)
aborting...

The crash seems to reliable reproducable on certain help pages
(gimp-tool-pencil) This could of course mean that the HTML is buggy but I
don't think that this should cause the renderer to crash.

I will attach a page that crashes together with the stylesheet it is using.
Comment 1 Sven Neumann 2004-03-09 10:46:00 UTC
Created attachment 25379 [details]
HTML file that crashes the renderer
Comment 2 Sven Neumann 2004-03-09 10:48:20 UTC
Created attachment 25380 [details]
stylesheet used
Comment 3 padraig.obriain 2004-03-09 13:21:24 UTC
How do I reproduce this problem?

What program do I use and where do I put the HTML file and stylesheet?
Comment 4 Sven Neumann 2004-03-09 14:25:29 UTC
I assume there is some example libgtkhtml2 browser that you could use,
isn't there?

The crash occurs with the GIMP2 helpbrowser plug-in. But given that
this is just a straight-forward minimal browser, it should be
reproducable with any browser based on libgthkhtml2.

The GIMP helpbrowser code can be found in GNOME CVS:
 http://cvs.gnome.org/bonsai/rview.cgi?cvsroot=/cvs/gnome&dir=gimp/plug-ins/helpbrowser
Comment 5 padraig.obriain 2004-03-09 14:35:47 UTC
My first try woul be to use the test program testgtkhtml
gtkhtml2/tests.

If I try to extract the HTML file using netscape I get an error. If I
use mozilla I can extract the HTML file but it does not crash in
testgtkhtml. Could you email me the HTML file.
Comment 6 Sven Neumann 2004-03-28 12:01:13 UTC
*** Bug 138275 has been marked as a duplicate of this bug. ***
Comment 7 padraig.obriain 2004-03-29 17:57:20 UTC
I am attemping to build gimp. I have the helpbroswser built but when I attempt
to run it it cannot find gimp-help.xml.

What am I omitting?
Comment 8 Sven Neumann 2004-04-06 17:34:03 UTC
You need to have gimp-help-2 installed. It's available from
ftp://ftp.gimp.org/pub/gimp/help/testing/

Sorry for not replying earlier; bugzilla was down last time I tried to add this
comment...
Comment 9 padraig.obriain 2004-04-07 09:25:50 UTC
I am got the Gimp Help Browser runnning. How do I cause it to crash?
Comment 10 Sven Neumann 2004-04-16 12:33:48 UTC
*** Bug 138400 has been marked as a duplicate of this bug. ***
Comment 11 Sven Neumann 2004-04-24 22:44:57 UTC
*** Bug 140962 has been marked as a duplicate of this bug. ***
Comment 12 padraig.obriain 2004-04-26 09:25:56 UTC
I am still wating for a reproducible test case.

I have gimp and its help browser running  but have not had it crash.
Comment 13 Ari Pollak 2004-04-26 12:36:26 UTC
I already gave one in #140962. "Open help (F1) and click on point 3.3.2 or 3.3.3."
Comment 14 Sven Neumann 2004-04-26 14:30:24 UTC
Try the help for the Airbrush tool. Crashes the help browser reproducibly here.
Comment 15 padraig.obriain 2004-04-27 08:48:59 UTC
The problem seems to occur when parsing html statements of the form

<img src="         /../images etc.

That is when there are spaces in the string before the filename. When I remove
the spaces in the files in gimp-help-2-0.2/html/en the crash went away.

I have not yet determined what is causing the crash.
Comment 16 Sven Neumann 2004-10-28 15:00:07 UTC
Created attachment 33168 [details]
a more uptodate page from gimp-help-2 which reliably triggers this problem

This HTML source from gimp-help-2 doesn't have spaces in the img src attribute
but still triggers the assertion.
Comment 17 Sven Neumann 2004-10-28 17:22:01 UTC
I am not sure but I think that the crash (failed assertion) always happens soon
after the following warning has been output:

(helpbrowser:31892): HtmlLayout-CRITICAL **: file htmlboxfactory.c: line 116
(html_box_factory_new_box): assertion `parent_box != NULL' failed

(I am using a current CVS checkout of gtkhtml2.)
Comment 18 Sven Neumann 2004-10-28 18:08:37 UTC
Ugh, I finally found out what's going wrong and it is indeed the GIMP help
browser that is doing the wrong thing here. There's code to generate an error
page in case a requested URL could not be loaded. That code is used from the
"request_url" handler. Now what happens is that if an image is missing, a
complete HTML error page is inserted where the image should have gone. This is
of course the wrong thing to do. However I think that gtkhtml2 should be able to
handle this and shouldn't crash. That's why I am leaving this report open for
you. Lowering the priority though.
Comment 19 Sven Arvidsson 2007-04-18 21:45:24 UTC
Is this still a problem? I moved some of the navigation images out of the way, but couldn't reproduce the bug.
Comment 20 André Klapper 2008-11-16 17:56:48 UTC
Closing this bug report as no further information has been provided. Please feel free to reopen this bug if you can provide the information asked for.
Thanks!