Project: JDT
Bug 233559 [implementation] NPE in DocumentAdapter
Reported: 2008-05-22 15:55:12 | Status: resolved fixed

Closed an editor right after startup. Will try to reproduce... java.lang.NullPointerException at org.eclipse.jdt.int.ui.javaeditor.DocumentAdapter.getContents(DocumentAdapter.java:371) at org.eclipse.jdt.int.ui.javaeditor.DocumentAdapter.getCharacters(DocumentAdapter.java:363) at org.eclipse.jdt.int.core.CompilationUnit.getContents(CompilationUnit.java:649) at org.eclipse.jdt.int.core.CompilationUnit$1.getContents(CompilationUnit.java:221) at org.eclipse.jdt.int.compiler.parser.Parser.parse(Parser.java:9483) at org.eclipse.jdt.int.compiler.parser.Parser.parse(Parser.java:9455) at org.eclipse.jdt.int.compiler.parser.Parser.dietParse(Parser.java:8102) at org.eclipse.jdt.int.compiler.Compiler.internalBeginToCompile(Compiler.java:696) at org.eclipse.jdt.int.compiler.Compiler.beginToCompile(Compiler.java:376) at org.eclipse.jdt.int.compiler.Compiler.resolve(Compiler.java:838) at org.eclipse.jdt.int.compiler.Compiler.resolve(Compiler.java:904) at org.eclipse.jdt.int.core.CompilationUnitProblemFinder.process(CompilationUnitProblemFinder.java:182) at org.eclipse.jdt.int.core.CompilationUnitProblemFinder.process(CompilationUnitProblemFinder.java:243) at org.eclipse.jdt.int.core.ReconcileWorkingCopyOperation.makeConsistent(ReconcileWorkingCopyOperation.java:190) at org.eclipse.jdt.int.core.ReconcileWorkingCopyOperation.executeOperation(ReconcileWorkingCopyOperation.java:89) at org.eclipse.jdt.int.core.JavaModelOperation.run(JavaModelOperation.java:709) at org.eclipse.jdt.int.core.JavaModelOperation.runOperation(JavaModelOperation.java:769) at org.eclipse.jdt.int.core.CompilationUnit.reconcile(CompilationUnit.java:1224) at org.eclipse.jdt.int.ui.text.java.JavaReconcilingStrategy.reconcile(JavaReconcilingStrategy.java:124) at org.eclipse.jdt.int.ui.text.java.JavaReconcilingStrategy.access$0(JavaReconcilingStrategy.java:108) at org.eclipse.jdt.int.ui.text.java.JavaReconcilingStrategy$1.run(JavaReconcilingStrategy.java:89) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.jdt.int.ui.text.java.JavaReconcilingStrategy.reconcile(JavaReconcilingStrategy.java:87) at org.eclipse.jdt.int.ui.text.java.JavaReconcilingStrategy.initialReconcile(JavaReconcilingStrategy.java:176) at org.eclipse.jdt.int.ui.text.CompositeReconcilingStrategy.initialReconcile(CompositeReconcilingStrategy.java:114) at org.eclipse.jdt.int.ui.text.JavaCompositeReconcilingStrategy.initialReconcile(JavaCompositeReconcilingStrategy.java:133) at org.eclipse.jface.text.reconciler.MonoReconciler.initialProcess(MonoReconciler.java:105) at org.eclipse.jdt.int.ui.text.JavaReconciler.initialProcess(JavaReconciler.java:388) at org.eclipse.jface.text.reconciler.AbstractReconciler$BackgroundThread.run(AbstractReconciler.java:173)

Files changed in fix:
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/DocumentAdapter.java