yet another crash with non-ascii filenames

Bug #166340 reported by Buliabyak-users
2
Affects Status Importance Assigned to Milestone
Inkscape
Fix Released
Critical
Jon A. Cruz

Bug Description

Sorry Jon, I know this is becoming annoying :)

Attached is the zip file with an SVG with non-ascii
filename (in my filename encoding, which is KOI8-R).
Opening it from GUI or from command line works fine.
However when I try to export it from command line it
crashes, obviously attempting to open some error box
(again!). The space in the filename does not seem to be
the reason, i.e. it also crashes for another KOI8-R
filename without spaces.

$ i не\ знаю.svg --export-png=test.png

** (process:8885): WARNING **: Running commandline

One or more extensions failed to load. The failed
extensions have been skipped. Inkscape will continue to
run normally but those extensions will be unavailable.
 For details to troubleshoot this problem, please refer
to the error log.

Emergency save activated!
Emergency save completed. Inkscape will close now.
If you can reproduce this crash, please file a bug at
www.inkscape.org
with a detailed description of the steps leading to the
crash, so we can fix it.

(process:8885): Gtk-CRITICAL **:
gtk_settings_get_for_screen: assertion `GDK_IS_SCREEN
(screen)' failed

(process:8885): GLib-GObject-CRITICAL **: g_object_get:
assertion `G_IS_OBJECT (object)' failed

(process:8885): GLib-GObject-WARNING **: value "TRUE"
of type `gboolean' is invalid or out of range for
property `visible' of type `gboolean'

(process:8885): Gtk-WARNING **: Screen for GtkWindow
not set; you must always set
a screen for a GtkWindow before using the window

(process:8885): Gdk-CRITICAL **:
gdk_pango_context_get_for_screen: assertion
`GDK_IS_SCREEN (screen)' failed

(process:8885): Pango-CRITICAL **:
pango_context_set_base_dir: assertion `context != NULL'
failed

(process:8885): Pango-CRITICAL **:
pango_context_set_font_description: assertion `context
!= NULL' failed

(process:8885): Pango-CRITICAL **:
pango_context_set_language: assertion `context != NULL'
failed

(process:8885): Pango-CRITICAL **: pango_layout_new:
assertion `context != NULL' failed

(process:8885): Pango-CRITICAL **:
pango_layout_set_text: assertion `layout != NULL' failed

(process:8885): Pango-CRITICAL **:
pango_layout_set_attributes: assertion `layout != NULL'
failed

(process:8885): Pango-CRITICAL **:
pango_layout_set_alignment: assertion `layout != NULL'
failed

etc. etc.

Revision history for this message
Buliabyak-users (buliabyak-users) wrote :
Revision history for this message
Buliabyak-users (buliabyak-users) wrote :

Here's the backtrace:

(gdb) run не\ знаю.svg
--export-png=test.png
Starting program: /home/d/ink/inkscape/src/inkscape не\
знаю.svg --export-png=test.png
Cannot open /dev/port: Permission denied
[Thread debugging using libthread_db enabled]
[New Thread 1087741248 (LWP 4855)]

** (process:4855): WARNING **: Running commandline

One or more extensions failed to load. The failed extensions
have been skipped. Inkscape will continue to run normally
but those extensions will be unavailable. For details to
troubleshoot this problem, please refer to the error log.

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1087741248 (LWP 4855)]
IA__g_utf8_validate (str=0x0, max_len=-1, end=0x0) at
gutf8.c:1530
1530 for (p = str; *p; p++)
Current language: auto; currently c
(gdb) bt
#0 IA__g_utf8_validate (str=0x0, max_len=-1, end=0x0) at
gutf8.c:1530
#1 0x0823a2a3 in Inkscape::IO::file_test (utf8name=0x0,
test=G_FILE_TEST_EXISTS) at io/sys.cpp:248
#2 0x082ba723 in Inkscape::Extension::Input::open
(this=0x839ba58, uri=0xbffff69c "не
знаю.svg")
    at extension/input.cpp:156
#3 0x082b8d88 in Inkscape::Extension::open (key=0x839ba58,
filename=0xbffff69c "не знаю.svg")
    at extension/system.cpp:98
#4 0x080d6313 in sp_main_console (argc=3, argv=0xbffff4b4)
at main.cpp:450
#5 0x08187f7e in Inkscape::NSApplication::Application::run
(this=0xbffff3e0)
    at application/application.cpp:131
#6 0x080d60a2 in main (argc=3, argv=0xbffff4b4) at main.cpp:308

Revision history for this message
Buliabyak-users (buliabyak-users) wrote :

I would not call it fixed, latest CVS does not crash but
does not work either:

$ inkscape не\ знаю.svg
--export-png=test.png

** (process:23075): WARNING **: Running commandline

** Message: file #0 is not valid UTF-8

** (process:23075): WARNING **: input filename conversion
failed for #0
One or more extensions failed to load. The failed extensions
have been skipped. Inkscape will continue to run normally
but those extensions will be unavailable. For details to
troubleshoot this problem, please refer to the error log.

** (process:23075): CRITICAL **: Inkscape::XML::Document*
sp_repr_read_file(const gchar*, const gchar*): assertion
`localFilename != NULL' failed

** (process:23075): CRITICAL **: Inkscape::XML::Document*
sp_repr_read_file(const gchar*, const gchar*): assertion
`localFilename != NULL' failed

** (process:23075): WARNING **: Specified document \xce\xc5
\xda\xce\xc1\xc0.svg cannot be opened (is it valid SVG file?)

(process:23075): Gtk-CRITICAL **: gtk_main_quit: assertion
`main_loops != NULL' failed

Revision history for this message
Jon A. Cruz (jon-joncruz) wrote :

Yes, fixed.
Crash and screen failure were from certain causes and with
certain symptoms. Those have been fixed.

Not opening is a different cause, with different
user-visible behavior, so if it's still there after this
latest code update, open a bug specifically on that.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.