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 52067 - GMarkup SEGV fix and speed improvements
GMarkup SEGV fix and speed improvements
Status: RESOLVED FIXED
Product: glib
Classification: Platform
Component: general
1.3.x
Other Linux
: Normal normal
: ---
Assigned To: gtkdev
gtkdev
Depends on:
Blocks:
 
 
Reported: 2001-03-13 19:10 UTC by Paolo Molaro
Modified: 2011-02-18 15:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch with the fixes. (10.91 KB, patch)
2001-03-13 19:12 UTC, Paolo Molaro
none Details | Review

Description Paolo Molaro 2001-03-13 19:10:59 UTC
The GMarkup test dies with a segfault with fail-8.gmarkup (in case of
errors it tries to report the element it failed in, but that is
already freed).
The patch also implements attributes and values as arrays instead of
a list as was discussed a while ago on gtk-devel-list and requires
fewer allocations (it caches the partial_chunck GString): this results
in about 15 % speedup (it's still quite slow, though).
A new test case is added.
Oh, and it removes about 80 lines of code.

Comments welcome.

lupus
Comment 1 Paolo Molaro 2001-03-13 19:12:25 UTC
Created attachment 400 [details] [review]
Patch with the fixes.
Comment 2 Havoc Pennington 2001-03-13 19:26:30 UTC
The patch looks good to me, thanks!
Comment 3 Owen Taylor 2001-05-30 20:48:12 UTC
Thu May 24 21:24:16 CEST 2001 Paolo Molaro <lupus@ximian.com>

	* gmarkup.c: back out change by mitch@convergence.de and apply patch
in
	bug id #52067 that fixes the same problem in a more complete manner.
	This fixes also a segfault for a malformed XML file and adds a new
	test case.