Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » SWT chrashes in GDI
SWT chrashes in GDI [message #520766] Mon, 15 March 2010 09:32 Go to next message
philipp huebner is currently offline philipp huebnerFriend
Messages: 67
Registered: July 2009
Member
Hi folks,

We developing an application using Eclipse RCP (with Ganymede, SWT 3.4.2). Our application chrashes by SWT in Image-drawing calls.

For example:
	String relativeURL = "icons/colors/red.gif";
	URL imageURL = ViewerEditUIPlugin.getPlugin().getBundle().getEntry(
		relativeURL);
	red = ImageDescriptor.createFromURL(imageURL);

combo.add(red.createImage(), "  " + getString("UI_ColorCombo_red"));


results in a crash like this:
Stack: [0x00030000,0x00130000),  sp=0x0012e158,  free space=1016k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [nvoglnt.dll+0x267239]

[error occurred during error reporting, step 120, id 0xc0000005]

Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j  org.eclipse.swt.internal.gdip.Gdip.Bitmap_LockBits(IIIII)I+0
J  org.eclipse.swt.graphics.Image.<init>(Lorg/eclipse/swt/graphics/Device;Ljava/lang/String;)V
v  ~RuntimeStub::alignment_frame_return Runtime1 stub
j  org.eclipse.jface.resource.URLImageDescriptor.createImage(ZLorg/eclipse/swt/graphics/Device;)Lorg/eclipse/swt/graphics/Image;+22
j  org.eclipse.jface.resource.ImageDescriptor.createImage(Z)Lorg/eclipse/swt/graphics/Image;+5
j  org.eclipse.jface.resource.ImageDescriptor.createImage()Lorg/eclipse/swt/graphics/Image;+2
j  org.teraport.viewer.edit.ui.common.ColorComboBoxToolbarContribution.createControl(Lorg/eclipse/swt/widgets/Composite;)Lorg/eclipse/swt/widgets/Control;+164
j  org.eclipse.jface.action.ControlContribution.fill(Lorg/eclipse/swt/widgets/ToolBar;I)V+2
j  org.eclipse.jface.action.ToolBarManager.update(Z)V+478
j  org.eclipse.jface.action.ToolBarManager.createControl(Lorg/eclipse/swt/widgets/Composite;)Lorg/eclipse/swt/widgets/ToolBar;+40


The crash is not reproduceable. I didn't found anything in SWT Bugzilla.
Does anybody have any suggestions/ ideas how to get rid of this?

Thank you
Re: SWT chrashes in GDI [message #521128 is a reply to message #520766] Tue, 16 March 2010 14:08 Go to previous message
Grant Gayed is currently offline Grant GayedFriend
Messages: 2150
Registered: July 2009
Senior Member
Hi,

This stack does not look familiar, it's difficult to know what the problem
is based solely on it. When you say the problem is not reproducable, do you
mean consistently, or ever? If you have a scenario where it happens
sometimes then you may be able to try some experiements:

- does changing the image being loaded help?
-> to another .gif?
-> to some other format?
- does it still happen with a recent eclipse milestone like
http://download.eclipse.org/eclipse/downloads/drops/S-3.6M6- 201003121448/index.php ?

I would suggest logging a report with swt at
https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Platform &component=SWT
and including the above information. It would also be particularly helpful
if you could provide a snippet (ideal template:
http://www.eclipse.org/swt/faq.php#whatisasnippet ) that reproduces the
problem for you, even if it's not consistent, and an image that can be used
to show the problem.

Grant


"philipp huebner" <philipp.huebner@teraport.de> wrote in message
news:hnkuqr$t91$1@build.eclipse.org...
> Hi folks,
>
> We developing an application using Eclipse RCP (with Ganymede, SWT 3.4.2).
Our application chrashes by SWT in Image-drawing calls.
>
> For example:
>
> String relativeURL = "icons/colors/red.gif";
> URL imageURL = ViewerEditUIPlugin.getPlugin().getBundle().getEntry(
> relativeURL);
> red = ImageDescriptor.createFromURL(imageURL);
>
> combo.add(red.createImage(), " " + getString("UI_ColorCombo_red"));
>
>
> results in a crash like this:
>
> Stack: [0x00030000,0x00130000), sp=0x0012e158, free space=1016k
> Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native
code)
> C [nvoglnt.dll+0x267239]
>
> [error occurred during error reporting, step 120, id 0xc0000005]
>
> Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
> j org.eclipse.swt.internal.gdip.Gdip.Bitmap_LockBits(IIIII)I+0
> J
org.eclipse.swt.graphics.Image.<init>(Lorg/eclipse/swt/graphics/Device;Ljava
/lang/String;)V
> v ~RuntimeStub::alignment_frame_return Runtime1 stub
> j
org.eclipse.jface.resource.URLImageDescriptor.createImage(ZL org/eclipse/swt/
graphics/Device;)Lorg/eclipse/swt/graphics/Image;+22
> j
org.eclipse.jface.resource.ImageDescriptor.createImage(Z)Lor g/eclipse/swt/gr
aphics/Image;+5
> j
org.eclipse.jface.resource.ImageDescriptor.createImage()Lorg /eclipse/swt/gra
phics/Image;+2
> j
org.teraport.viewer.edit.ui.common.ColorComboBoxToolbarContr ibution.createCo
ntrol(Lorg/eclipse/swt/widgets/Composite;)Lorg/eclipse/swt/w idgets/Control;+
164
> j
org.eclipse.jface.action.ControlContribution.fill(Lorg/eclip se/swt/widgets/T
oolBar;I)V+2
> j org.eclipse.jface.action.ToolBarManager.update(Z)V+478
> j
org.eclipse.jface.action.ToolBarManager.createControl(Lorg/e clipse/swt/widge
ts/Composite;)Lorg/eclipse/swt/widgets/ToolBar;+40
>
>
> The crash is not reproduceable. I didn't found anything in SWT Bugzilla.
> Does anybody have any suggestions/ ideas how to get rid of this?
>
> Thank you
>
Previous Topic:Displaying animated GIF in table cell, issues with GC
Next Topic:adding actions on text editor
Goto Forum:
  


Current Time: Sun Dec 08 22:06:08 GMT 2024

Powered by FUDForum. Page generated in 0.02508 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top