Bug 1715882

Summary: GIMP crashes on an svg file
Product: [Fedora] Fedora Reporter: udayb <udayreddy>
Component: gimpAssignee: Josef Ridky <jridky>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: unspecified    
Version: 30CC: alex.ploumistos, caillon+fedoraproject, gnome-sig, igor.raits, john.j5live, jridky, klember, mclasen, nphilipp, phracek, rhughes, rstrode, sandmann, tcallawa, zdohnal
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: gimp-2.10.12-2.fc30 gimp-2.10.12-2.fc29 gimp-2.10-2920190806121754.6c81f848 gimp-2.10-3020190806121754.a5b0195c Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-08-03 01:17:01 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Fix for SVG size computation issue in how gimp was calling librsvg none

Description udayb 2019-05-31 13:58:23 UTC
Description of problem:

GIMP crashes when opening https://upload.wikimedia.org/wikipedia/commons/0/05/Dodecahedron_light_blue.svg

Version-Release number of selected component (if applicable):

gimp-2.10.10-1.module_f30+3878+d4400ad3.x86_64

How reproducible:

Always


Steps to Reproduce:
1. Download and open the file: https://upload.wikimedia.org/wikipedia/commons/0/05/Dodecahedron_light_blue.svg
with GIMP. 


Actual results:

Plug-in crashed: "file-svg"
(/usr/lib64/gimp/2.0/plug-ins/file-svg/file-svg)

The dying plug-in may have messed up GIMP's internal state. You may want to save your images and restart GIMP to be on the safe side.


Opening '.../Dodecahedron_light_blue.svg' failed: Procedure 'file-svg-load' returned no return values


Expected results:


Additional info:

Comment 1 udayb 2019-05-31 13:59:02 UTC
I haven't tried other SVG files, nor this file on another system. But this clearly looks like a bug.

Comment 2 Josef Ridky 2019-06-03 06:48:25 UTC
I have tried that with different SVG file and GIMP crashed as well, so it looks like general SVG file reading issue.

Comment 3 Josef Ridky 2019-06-03 07:53:34 UTC
From further investigation, this issue is caused by librsvg2 package.

When is used librsvg2-2.45.6-1.fc30, gimp plugin crashes with following backtrace:
---- START ----
loading menu '/usr/share/gimp/2.0/menus/image-menu.xml' for /image-menubar

(file-svg:20920): librsvg-WARNING **: 09:51:17.437: Handle is still loading; call rsvg_handle_close() first
thread '<unnamed>' panicked at 'Handle is not loaded', rsvg_internals/src/c_api.rs:656:13
stack backtrace:
   0: <unknown>
   1: <unknown>
   2: <unknown>
   3: <unknown>
   4: <unknown>
   5: <unknown>
   6: <unknown>
   7: <unknown>
   8: <unknown>
   9: gimp_main
  10: __libc_start_main
  11: <unknown>
fatal runtime error: failed to initiate panic, error 5
/usr/lib64/gimp/2.0/plug-ins/file-svg/file-svg: fatal error: Aborted
Terminating plug-in: '/usr/lib64/gimp/2.0/plug-ins/file-svg/file-svg'
---- END ----

When is used librsvg2-2.45.5-3.fc30, all works as expected. 
Moving this issue to librsvg2 package.

Comment 4 Kalev Lember 2019-07-15 15:11:48 UTC
I think this is gimp doing something wrong with RsvgHandle (not closing?). Older librsvg seemed to just warn about it, but newer version also crashes. I filed an upstream issue about that at https://gitlab.gnome.org/GNOME/librsvg/issues/486

Comment 5 Kalev Lember 2019-07-15 17:21:00 UTC
As per librsvg https://gitlab.gnome.org/GNOME/librsvg/issues/486, librsvg upstream considers this a gimp bug: https://gitlab.gnome.org/GNOME/gimp/issues/2561

Moving the ticket back to gimp.

Comment 6 Tom "spot" Callaway 2019-07-29 17:14:59 UTC
Created attachment 1594380 [details]
Fix for SVG size computation issue in how gimp was calling librsvg

Taken from https://gitlab.gnome.org/GNOME/gimp/commit/38e87c2d16d0e519b35be9b2cdc9e5e28dbfab54

Confirmed that it resolves the issue for me.

Comment 7 Fedora Update System 2019-07-31 12:39:22 UTC
FEDORA-2019-1939456421 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-1939456421

Comment 8 Fedora Update System 2019-07-31 12:39:24 UTC
FEDORA-2019-a9479d664d has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2019-a9479d664d

Comment 9 Fedora Update System 2019-08-01 03:28:38 UTC
gimp-2.10.12-2.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-1939456421

Comment 10 Fedora Update System 2019-08-01 05:33:43 UTC
gimp-2.10.12-2.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-a9479d664d

Comment 11 Fedora Update System 2019-08-03 01:17:01 UTC
gimp-2.10.12-2.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.

Comment 12 Fedora Update System 2019-08-08 13:06:59 UTC
FEDORA-MODULAR-2019-371c062595 has been submitted as an update to Fedora 29 Modular. https://bodhi.fedoraproject.org/updates/FEDORA-MODULAR-2019-371c062595

Comment 13 Fedora Update System 2019-08-08 13:07:02 UTC
FEDORA-MODULAR-2019-f5cc9ea786 has been submitted as an update to Fedora 30 Modular. https://bodhi.fedoraproject.org/updates/FEDORA-MODULAR-2019-f5cc9ea786

Comment 14 Fedora Update System 2019-08-09 05:04:26 UTC
gimp-2.10-3020190806121754.a5b0195c has been pushed to the Fedora 30 Modular testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-MODULAR-2019-f5cc9ea786

Comment 15 Fedora Update System 2019-08-09 05:06:19 UTC
gimp-2.10-2920190806121754.6c81f848 has been pushed to the Fedora 29 Modular testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-MODULAR-2019-371c062595

Comment 16 Fedora Update System 2019-08-10 06:31:09 UTC
gimp-2.10.12-2.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.

Comment 17 Fedora Update System 2019-08-17 04:26:46 UTC
gimp-2.10-2920190806121754.6c81f848 has been pushed to the Fedora 29 Modular stable repository. If problems still persist, please make note of it in this bug report.

Comment 18 Fedora Update System 2019-08-17 06:26:54 UTC
gimp-2.10-3020190806121754.a5b0195c has been pushed to the Fedora 30 Modular stable repository. If problems still persist, please make note of it in this bug report.