Bug 13945 - NPE opening editor
Summary: NPE opening editor
Status: RESOLVED FIXED
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows XP
: P1 normal (vote)
Target Milestone: ---   Edit
Assignee: Dejan Glozic CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-04-16 16:55 EDT by Peter Burka CLA
Modified: 2002-04-22 17:13 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Burka CLA 2002-04-16 16:55:37 EDT
Build 20020321

I double clicked on an .xsd file.
It looked like the PDE was trying to open a manifest editor on the file 
(incorrectly).
An error dialog appeared with a NPE.

Here's the NPE stack trace:

java.lang.IllegalArgumentException: Argument cannot be null
	at org.eclipse.swt.SWT.error(SWT.java:1873)
	at org.eclipse.swt.SWT.error(SWT.java:1819)
	at org.eclipse.swt.graphics.GC.drawText(GC.java(Compiled Code))
	at org.eclipse.swt.graphics.GC.drawText(GC.java:1197)
	at org.eclipse.update.ui.forms.internal.SectionForm.paint
(SectionForm.java:121)
	at org.eclipse.update.ui.forms.internal.SectionForm.paintControl
(SectionForm.java:135)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java
(Compiled Code))
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java
(Compiled Code))
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code))
	at org.eclipse.swt.widgets.Composite.WM_PAINT(Composite.java(Compiled 
Code))
	at org.eclipse.swt.widgets.Control.windowProc(Control.java(Compiled 
Code))
	at org.eclipse.swt.widgets.Display.windowProc(Display.java(Compiled 
Code))
	at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method)
	at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java(Compiled 
Code))
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java
(Compiled Code))
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java
(Compiled Code))
	at org.eclipse.ui.internal.Workbench.run(Workbench.java:705)
	at org.eclipse.core.internal.boot.InternalBootLoader.run
(InternalBootLoader.java:777)
	at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319)
	at java.lang.reflect.Method.invoke(Native Method)
	at org.eclipse.core.launcher.Main.basicRun(Main.java:196)
	at org.eclipse.core.launcher.Main.run(Main.java:555)
	at org.eclipse.core.launcher.Main.main(Main.java:396)

Then there was a second, possibly unrelated, problem:
I tried to drag the error dialog, and then the VM started thrashing.
After a minute or so, the whole VM crashed (i.e. javaw GPF'ed).  There was 
nothing of interest in the javacore file.

Here's the javacore file:

Exception code: C0000005 ACCESS_VIOLATION
Fault address:  716706BD 01:0009F6BD D:\eclipse\jre\bin\classic\jvm.dll

Registers:
EAX:068A0000
EBX:00265710
ECX:05774A30
EDX:068A0004
ESI:008301AC
EDI:00831074
CS:EIP:001B:716706BD
SS:ESP:0023:0006E460  EBP:0006E4AC
DS:0023  ES:0023  FS:0038  GS:0000
Flags:00010297

Tue Apr 16 16:58:37 2002


J2RE 1.3.0 IBM build cn130-20010925
D:\eclipse\jre\bin\javaw.exe -classpath D:\eclipse\startup.jar 
org.eclipse.core.launcher.Main -application org.eclipse.ui.workbench -ws 
win32 -endsplash D:\eclipse\eclipse.exe -endsplash 1377240 

System Properties
-----------------
Java Home Dir:	D:\eclipse\jre
Java DLL Dir:	D:\eclipse\jre\bin
Sys Classpath:
	D:\eclipse\jre\lib\rt.jar;D:\eclipse\jre\lib\i18n.jar;D:\eclipse\jre\cl
asses
User Args:
	-Djava.class.path=C:\Program Files\IBM\IBM CICS Transaction 
Gateway\Classes\CTGCLIENT.JAR;C:\Program Files\IBM\IBM CICS Transaction 
Gateway\Classes\CTGSERVER.JAR;C:\Program Files\IBM\IBM CICS Transaction 
Gateway\Classes\CICSJ2EE.JAR;C:\Program Files\IBM\IBM CICS Transaction 
Gateway\Classes\CTGSAMPLES.JAR
	-Djava.class.path=D:\eclipse\startup.jar


Current Thread Details
----------------------
    "main" (TID:0x9587e0, sys_thread_t:0x2658e8, state:R, native ID:0x74c) 
prio=5: 
pending=0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0
Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E
0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^
E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw^E0Jw
^E0Jw^E0Jw
EXCEPTION IN JAVACORE DUMP - ABORTING
Comment 1 Peter Burka CLA 2002-04-16 17:02:32 EDT
The first error seems repeatable, and I think that it's related to the PDE.

Whenever I try to double click on the fdml.xsd file a PDE Extension Point 
Schema editor opens and the error occurs.

This editor should NOT crash if it's opened on a schema which isn't an 
extension point.  Actually, it shouldn't crash for any input.


Comment 2 Dejan Glozic CLA 2002-04-16 17:07:25 EDT
Could you please attached the file to be able to debug?
Comment 3 Dejan Glozic CLA 2002-04-22 17:13:10 EDT
Schema editor was modified to reject XML Schema files that are not extension 
point schemas (do not have the expected annotation). Editor will open directly 
into the Source page for these file and will refuse to leave it.

In addition, PDE has changed content type of its shema files from 'xsd' 
to 'exsd'. PDE didn't register its editor as default for 'xsd' extension even 
before, but is now dropping registration for 'xsd' altogether.