Eclipse Crash due to net_sf_colorer.dll

46 views
Skip to first unread message

Vinay Kumar

unread,
Aug 1, 2013, 4:23:12 AM8/1/13
to col...@googlegroups.com

I am using eclipse colorer library. I use swt TextColorer API in my custom eclipse plugin in simple dialog( see attachment). I have configured dll files in Manifest file like below:

Bundle-NativeCode: config/os/win32/x86/net_sf_colorer.dll;osname=Win32;processor=x86,
 config/os/win32/x86_64/net_sf_colorer.dll;osname=Win32;processor=x86_64,
 config/os/linux/x86/libnet_sf_colorer.so;osname=linux;processor=x86,
 config/os/linux/x86_64/libnet_sf_colorer.so;osname=linux;processor=x86_64,
 config/os/macosx/ppc/libnet_sf_colorer.jnilib;osname=macosx;processor=ppc,
 config/os/macosx/x86/libnet_sf_colorer.jnilib;osname=macosx;processor=x86,
 config/os/macosx/x86_64/libnet_sf_colorer.jnilib;osname=macosx;processor=x86_64

Everything works initially. If I do few edits in dialog, eclipse crashes. Below are the details: ( also see attachment for detailed eclipse logs)

What could be the issue? Is it issue with dll file?

-Vinay.


#
# A fatal error has been detected by the Java Runtime Environment:
#
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x7c910f1e, pid=6988, tid=7800
#
# JRE version: 7.0_21-b11
# Java VM: Java HotSpot(TM) Client VM (23.21-b01 mixed mode windows-x86 )
# Problematic frame:
C  [ntdll.dll+0x108f3]  wcsncpy+0x374
C  [net_sf_colorer.dll+0x300b9]

hs_err_pid4700.log

Igor Russkih

unread,
Aug 2, 2013, 6:41:48 AM8/2/13
to colorer
Vinay,

Does regular colorer plugin works fine at the same time?

From stack that looks like a simpe null pointer.

Have you recompiled dll by yourself?

  Igor


--
You received this message because you are subscribed to the Google Groups "Colorer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to colorer+u...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Vinay Kumar

unread,
Aug 2, 2013, 7:06:04 AM8/2/13
to col...@googlegroups.com
Hi Igor,

Regular plug-in did not crash.

What I observe is regular plug-in's Manifest is different from my plugin's manifest for the configuration of dlls. Any thoughts how dll are configured in the regular plun-in?

No. I have not complied manually.

Any tips would be highly appreciated.

Regards,
-Vinay.

Igor Russkih

unread,
Aug 2, 2013, 7:47:25 AM8/2/13
to colorer
I don't think manifest somehow impacts this issue.

What do you mean with "few edits in dialog"? Are these edits in colorer's editor?

The exception happens in Editor's destructor, as a result of AttributeScriptValueDialog.okPressed.

Is it possible that you have some uninitialized editor?

It looks like colorer fails in non-standard life-cycle situation, which occurs in your plugin, but never happens in colorer plugin.

I think colorer's native logs could help, but for that you need to recompile colorer java part and change

    net/sf/colorer/impl/Logger.java:TRACE


  Igor

Vinay Kumar

unread,
Aug 2, 2013, 8:14:58 AM8/2/13
to col...@googlegroups.com
Looks like the problem is solved.

Before the code was :
whenever a dialog is opened:
ParserFactory pf = new ParserFactory(filePath);
TextColorer textColorer = new TextColorer(pf, new ColorManager());


Now What i did was I have initialzed ParserFactory as singleton in bundle activator class.

TextColorer textColorer = new TextColorer(ColorerActivator.getParserFactory(), new ColorManager());

It works! :)

The issue could be due to creating a ParserFactory instance for every instance of a dialog.

Thanks,
Reply all
Reply to author
Forward
0 new messages