FS#56919 - [gweled] segfaults
Attached to Project:
Arch Linux
Opened by Konstantinos Tampouris (ktamp) - Monday, 01 January 2018, 21:05 GMT
Last edited by Antonio Rojas (arojas) - Saturday, 29 September 2018, 09:11 GMT
Opened by Konstantinos Tampouris (ktamp) - Monday, 01 January 2018, 21:05 GMT
Last edited by Antonio Rojas (arojas) - Saturday, 29 September 2018, 09:11 GMT
|
Details
Description:
'gweled' does not start. When starting 'gweled' from the terminal, the following message is displayed: (gweled:1861): GLib-WARNING **: GError set over the top of a previous GError or uninitialized memory. This indicates a bug in someone's code. You must ensure an error is NULL before it's set. The overwriting error message was: Operation not supported Segmentation fault Additional info: * package version: gweled 0.9.1-4 Steps to reproduce: Just run 'gweled'. |
This task depends upon
Closed by Antonio Rojas (arojas)
Saturday, 29 September 2018, 09:11 GMT
Reason for closing: Fixed
Additional comments about closing: gweled 0.9.1-5
Saturday, 29 September 2018, 09:11 GMT
Reason for closing: Fixed
Additional comments about closing: gweled 0.9.1-5
[eschwartz@didactylos ~]$ gweled
(gweled:21645): GLib-WARNING **: GError set over the top of a previous GError or uninitialized memory.
This indicates a bug in someone's code. You must ensure an error is NULL before it's set.
The overwriting error message was: Operation not supported
Segmentation fault
[eschwartz@didactylos ~]$ gweled
double free or corruption (out)
Aborted
```
It seems to sporadically switch between the two errors.
Unfortunately, Eric has had very little time to do anything recently, and the package was anyways not really touched since 2012 or so (except to rebuild for hooks and .MTREE). It's also seen no upstream development since around then, either. So I don't know what the odds are that this will get fixed.
BBS: https://bbs.archlinux.org/viewtopic.php?id=234202
Patch: https://launchpadlibrarian.net/355791454/gweled-fix-librsvg-segfault.patch
Unfortunately, the patch leads to a 404 not found error, and since it was linked directly instead of linking to the actual bugreport that contained it, and the forum poster does not seem to have an interest in reporting this here...
Well, I assume it is probably this launchpad bug: https://bugs.launchpad.net/gweled/+bug/1741664
Which would explain why the patch itself is gone, because a v1 patch was removed from that bug and replaced with a v2. Lesson learned: linking the patch file is *stupid*, linking the bug itself and allowing the bug wranglers and developers *who have a capable and working brain* to select the attachment from the bug report, is sane.
This also allows us to know where the patch came from, so we know why we should trust it.
...
Sorry for the rant. :)
(Technically there's still a bug with Gweled's error handling, but without the librsvg bug it doesn't get triggered.)
librsvg-CRITICAL **: 13:52:36.617: rsvg_handle_write: assertion 'error == NULL || *error == NULL' failed
Segmentation fault
-------
gweled 0.9.1-4
librsvg 2:2.44.4-1
-------
Works if downgrade librsvg 2:2.44.2-1
I don't know whether librsvg would consider this something to be fixed on their side. On one hand it does break client code. On the other hand, standard error handling in GLib requires[1] that:
> A GError* must be initialized to NULL before passing its address to a function that can report errors.
so Gweled wasn't using the API correctly.
[1] https://developer.gnome.org/glib/stable/glib-Error-Reporting.html