Segfault after opening JVM scripts dialog

Bug #346721 reported by dopelover
18
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
Won't Fix
Low
ishmal

Bug Description

Inkscape segafaults after calling "Scripts..." dialog twice.

How to reproduce:
1) Open inkscape
2) Click View>Scripts... (some complaints about jvm appears on standard output)
3) Click just another time View>Scripts... and Inkscape will receive segfault.

This problem affects version 20959.

Revision history for this message
dopelover (dopelover) wrote :
Revision history for this message
Alvin Penner (apenner) wrote :

running Windows XP and Inkscape build 20967, I cannot reporoduce this crash.
attached are my exit messages.

Revision history for this message
jazzynico (jazzynico) wrote :

Confirmed on Ubuntu, Inkscape build 21356.

Changed in inkscape:
milestone: none → 0.47
status: New → Confirmed
importance: Undecided → High
tags: added: crash regression
Revision history for this message
Johan Engelen (johanengelen) wrote :

I think I fixed it in svn rev. 21366. Please check again.

Changed in inkscape:
status: Confirmed → Incomplete
Revision history for this message
jazzynico (jazzynico) wrote :

Inkscape no longer crashes, but the scripts dialog doesn't open either...
The gdb message is slightly different this time:
-----
** Message: JavaBinderyImpl:
** Message: getCreateVMFunc: Loading JVM: /usr/lib/jvm/java-6-openjdk/jre/lib/i386/client/libjvm.so
** Message:

** Message: JavaBinderyImpl:
** Message: Class path is: '-Djava.class.path=/usr/local/share/inkscape/bind/java/classes'
** Message:

** Message: JavaBinderyImpl:
** Message: Lib path is: '-Djava.library.path=/usr/local/share/inkscape/bind/java/libm'
** Message:

** (inkscape:20658): WARNING **: JavaBinderyImpl err:

** (inkscape:20658): WARNING **: JNI_CreateJavaVM() failed

** (inkscape:20658): WARNING **:
-----

Revision history for this message
m@ (mattbster) wrote :

No crash same problem as JazzyNico. svn 21414 linux

Revision history for this message
Alvin Penner (apenner) wrote :

running Win32 build 21453, the scripts appear to be behaving properly.

I'm going to re-open this report since it appears to be a linux issue.

Changed in inkscape:
status: Incomplete → New
tags: added: linux
Revision history for this message
jazzynico (jazzynico) wrote :

I still have this bug on Ubuntu 9.04, Inskcape rev. 21792 (but not on Windows).
The path used in the following messages doesn't exist on my computer:
** Message: Class path is: '-Djava.class.path=/usr/local/share/inkscape/bind/java/classes'
** Message: Lib path is: '-Djava.library.path=/usr/local/share/inkscape/bind/java/libm'

I also have java-6-sun installed on the same computer, but not as the default JVM.
Could someone else confirm this bug?

Revision history for this message
su_v (suv-lp) wrote :

I'd like to but can't confirm this bug on OS X 10.5.7 due to bug #373514 (which still is present with Inkscape 0.47pre1 on OS X 10.5.7, default Apple Java install with all updates, no other Java versions installed from Sun). Jumping in here because if there's a chance that the java bindings/scripts dialog gets new attention I'd like to add a plea for including it for OS X as well.

Revision history for this message
jazzynico (jazzynico) wrote :

Just compiled rev. 21803 on Vista, and sadly I now have the same bug. I've noticed a difference between this build and 21627, when the script is launched:
With 21627, the classpath is:
** Message: JavaBinderyImpl:
** Message: Class path is: '-Djava.class.path=C:/Users/Nicolas/Desktop/Inkscape/inkscape/share/bind/java/classes;C:/Users/Nicolas/Desktop/Inkscape/inkscape/share/bind/java/lib/inkscape.jar;C:/Users/Nicolas/Desktop/Inkscape/inkscape/share/bind/java/lib/jruby-engine.jar;C:/Users/Nicolas/Desktop/Inkscape/inkscape/share/bind/java/lib/jruby.jar;C:/Users/Nicolas/Desktop/Inkscape/inkscape/share/bind/java/lib/js-engine.jar;C:/Users/Nicolas/Desktop/Inkscape/inkscape/share/bind/java/lib/js.jar;C:/Users/Nicolas/Desktop/Inkscape/inkscape/share/bind/java/lib/jython-engine.jar;C:/Users/Nicolas/Desktop/Inkscape/inkscape/share/bind/java/lib/jython.jar'

With 21803, it's a bit shorter:
** Message: JavaBinderyImpl:
** Message: Class path is: '-Djava.class.path=C:/Users/Nicolas/Desktop/Inkscape/SVN/inkscape/inkscape/share/bind/java/classes'

Revision history for this message
jazzynico (jazzynico) wrote :

I still have this bug with all my SVN builds (Windows XP, Vista, and Ubuntu 9.04).
I've just found out that win32 snapshots from modevia are not affected. The only difference with my SVN builds is that they have a share/bind/java/lib directory which doesn't exists in SVN. If you copy it to the SVN build (win32), it works well!

Indeed, this directory is used by src/bind/javabind.cpp to populate INKSCAPE_JAVADIR. That's the reason why my SVN builds showed a shortened path. It contains some jar files (inkscape.jar, jython.jar, jruby.jar...). Inkscape.jar can be generated by creating a jar with /src/bind/java/org, and I don't know where the others come from, and how they can be automatically installed.

I can manually add the files to SVN and tell the installer to make a copy to share/, but I'm not sure it is the expected procedure. Could someone give a clue?

Changed in inkscape:
status: New → Confirmed
Revision history for this message
theAdib (theadib) wrote :

assigning ishmal to check.

Changed in inkscape:
assignee: nobody → ishmal (ishmalius)
summary: - Segfault after opening scripts dialog
+ Segfault after opening JVM scripts dialog
su_v (suv-lp)
tags: added: java
Revision history for this message
jazzynico (jazzynico) wrote :

@theAdib, win32 is affected too when you compile it from SVN. Modevia's archives (manually?) include the missing java classes, but there's no trace of it in SVN.

tags: added: build
removed: linux
tags: removed: crash
Revision history for this message
Krzysztof Kosinski (tweenk) wrote :

It's a build issue. The Java classes under src/bind/java are not compiled or installed when using Automake, and this is the reason why it doesn't work.

Revision history for this message
jazzynico (jazzynico) wrote :

@Krzysztof. The classes under src/bind/java contains inkscape.jar only, and not jruby.jar, jython.jar, etc.
But at least, it should fix the minimum (opening the script dialog box).

Revision history for this message
su_v (suv-lp) wrote :

menu 'View > Scripts…' has been disabled in rev. 22569

ScislaC (scislac)
Changed in inkscape:
milestone: 0.47 → none
Revision history for this message
jazzynico (jazzynico) wrote :

Lowering importance now that the script dialog is disabled in Inkscape.

Changed in inkscape:
importance: High → Low
status: Confirmed → Triaged
Revision history for this message
jazzynico (jazzynico) wrote :

The Java code was removed from Inkscape revision 12428 (http://bazaar.launchpad.net/~inkscape.dev/inkscape/trunk/revision/12428).
Closing won't fix.

Changed in inkscape:
status: Triaged → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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