Internal error attempting to open a SVG file with <image xlink:href="a\b.png"/>
Summary:
Trying to an SVG file containing
<image x="-44680.37" y="-24131.27" width="34805.56" height="55555.57" xlink:href="Nanahi_Images\Nanahi_ImgID2.png"/>
crashes inkscape on startup / file load.
Full file to test:
Auto-reduced SVG file:
<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" width="8.26772in" height="11.6929in" version="1.1" style="shape-rendering:geometricPrecision; text-rendering:geometricPrecision; image-rendering:optimizeQuality; fill-rule:evenodd; clip-rule:evenodd"
xmlns:xlink="http://www.w3.org/1999/xlink">
<defs>
<image x="-44680.37" y="-24131.27" width="34805.56" height="55555.57" xlink:href="Nanahi_Images\Nanahi_ImgID2.png"/>
Steps to reproduce:
- open inkscape with attached file
What happened?
"Inkscape encountered an internal error and will close now"
segmentation fault in the console. GDB backtrace:
Thread 1 "inkscape" received signal SIGSEGV, Segmentation fault.
0x00007ffff6d10fd1 in Inkscape::Pixbuf::ensurePixelFormat(Inkscape::Pixbuf::PixelFormat) () from /usr/bin/../lib/inkscape/libinkscape_base.so
(gdb) bt
#0 0x00007ffff6d10fd1 in Inkscape::Pixbuf::ensurePixelFormat(Inkscape::Pixbuf::PixelFormat) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#1 0x00007ffff6d110c3 in Inkscape::Pixbuf::getPixbufRaw(bool) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#2 0x00007ffff6d1aaab in Inkscape::Pixbuf::create_from_buffer(char*&&, unsigned long, double, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#3 0x00007ffff6d1b150 in Inkscape::Pixbuf::create_from_buffer(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, double, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) ()
at /usr/bin/../lib/inkscape/libinkscape_base.so
#4 0x00007ffff705f5fe in SPImage::getBrokenImage(double, double) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#5 0x00007ffff7068a5e in SPImage::update(SPCtx*, unsigned int) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#6 0x00007ffff70a8fd3 in SPObject::updateDisplay(SPCtx*, unsigned int) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#7 0x00007ffff7063132 in SPGroup::update(SPCtx*, unsigned int) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#8 0x00007ffff70a8fd3 in SPObject::updateDisplay(SPCtx*, unsigned int) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#9 0x00007ffff7063132 in SPGroup::update(SPCtx*, unsigned int) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#10 0x00007ffff70a8fd3 in SPObject::updateDisplay(SPCtx*, unsigned int) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#11 0x00007ffff7063132 in SPGroup::update(SPCtx*, unsigned int) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#12 0x00007ffff70bd4ad in SPRoot::update(SPCtx*, unsigned int) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#13 0x00007ffff70a8fd3 in SPObject::updateDisplay(SPCtx*, unsigned int) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#14 0x00007ffff7674246 in SPDocument::_updateDocument(int) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#15 0x00007ffff767431a in SPDocument::ensureUpToDate() () at /usr/bin/../lib/inkscape/libinkscape_base.so
#16 0x00007ffff766277e in SPDesktop::init(SPNamedView*, Inkscape::UI::Widget::Canvas*, SPDesktopWidget*) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#17 0x00007ffff7617937 in SPDesktopWidget::SPDesktopWidget(InkscapeWindow*, SPDocument*) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#18 0x00007ffff775a915 in InkscapeWindow::InkscapeWindow(SPDocument*) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#19 0x00007ffff775b618 in InkscapeApplication::window_open(SPDocument*) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#20 0x00007ffff775b860 in InkscapeApplication::create_window(SPDocument*, bool) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#21 0x00007ffff775c05c in InkscapeApplication::process_document(SPDocument*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#22 0x00007ffff775c182 in InkscapeApplication::on_open(std::vector<Glib::RefPtr<Gio::File>, std::allocator<Glib::RefPtr<Gio::File> > > const&, Glib::ustring const&) () at /usr/bin/../lib/inkscape/libinkscape_base.so
#23 0x00007ffff65021f1 in () at /usr/lib/libgiomm-2.4.so.1
#24 0x00007ffff553b6c0 in g_closure_invoke () at /usr/bin/../lib/inkscape/../libgobject-2.0.so.0
#25 0x00007ffff5569cbb in () at /usr/bin/../lib/inkscape/../libgobject-2.0.so.0
#26 0x00007ffff555aaa7 in g_signal_emit_valist () at /usr/bin/../lib/inkscape/../libgobject-2.0.so.0
#27 0x00007ffff555ad34 in g_signal_emit () at /usr/bin/../lib/inkscape/../libgobject-2.0.so.0
#28 0x00007ffff5666bde in () at /usr/bin/../lib/inkscape/../libgio-2.0.so.0
#29 0x00007ffff5666e6c in g_application_run () at /usr/bin/../lib/inkscape/../libgio-2.0.so.0
#30 0x00007ffff5e39850 in () at /usr/lib/libc.so.6
#31 0x00007ffff5e3990a in __libc_start_main () at /usr/lib/libc.so.6
#32 0x0000555555556c85 in _start ()
What should have happened?
Should have opened regularly, or remove and ideally notify me about broken elements.
Version info
Inkscape 1.2.2 (b0a8486541, 2022-12-01)
GLib version: 2.76.4
GTK version: 3.24.38
glibmm version: 2.66.6
gtkmm version: 3.24.7
libxml2 version: 2.11.4
libxslt version: 1.1.38
Cairo version: 1.17.8
Pango version: 1.50.14
HarfBuzz version: 8.0.1
OS version: Arch Linux