This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 37178 - ClassCastException when reload modified file (Position kinds)
Summary: ClassCastException when reload modified file (Position kinds)
Status: VERIFIED DUPLICATE of bug 27773
Alias: None
Product: platform
Classification: Unclassified
Component: Text (show other bugs)
Version: 3.x
Hardware: Sun SunOS
: P2 blocker (vote)
Assignee: Petr Nejedly
URL:
Keywords:
: 36975 37786 (view as bug list)
Depends on:
Blocks:
 
Reported: 2003-11-12 20:39 UTC by Chihin Ko
Modified: 2008-12-22 19:07 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Chihin Ko 2003-11-12 20:39:47 UTC
if source file are edit by other editor and
rebuild, 
     either IDE tries to reload, or use file
explorer to open
     the file, following exception occurred:
     

    Annotation: The document glue.cc could not be
loaded.
java.lang.ClassCastException:
org.openide.text.PositionRef$Manager$OffsetKind
	at
org.openide.text.PositionRef.getPosition(PositionRef.java:134)
	at
org.openide.text.DocumentLine.updatePositionRef(DocumentLine.java:432)
	at
org.openide.text.DocumentLine.notifyMove(DocumentLine.java:403)
	at
org.openide.text.DocumentLine$Set.linesMoved(DocumentLine.java:711)
	at
org.openide.text.LineListener.insertUpdate(LineListener.java:119)
	at
org.openide.util.WeakListener$Document.insertUpdate(WeakListener.java:705)
	at
javax.swing.text.AbstractDocument.fireInsertUpdate(AbstractDocument.java:184)
	at
org.netbeans.editor.BaseDocument.fireInsertUpdate(BaseDocument.java:1004)
	at
org.netbeans.editor.BaseDocument.insertString(BaseDocument.java:583)
	at
org.netbeans.editor.Analyzer.read(Analyzer.java:501)
	at
org.netbeans.editor.BaseDocument.read(BaseDocument.java:917)
	at org.netbeans.editor.BaseKit.read(BaseKit.java:411)
	at
javax.swing.text.DefaultEditorKit.read(DefaultEditorKit.java:132)
	at
org.openide.text.CloneableEditorSupport.loadFromStreamToKit(CloneableEditorSupport.java:841)
	at
org.openide.text.EditorSupport$Del.superLoadFromStreamToKit(EditorSupport.java:661)
	at
org.openide.text.EditorSupport.loadFromStreamToKit(EditorSupport.java:352)
	at
org.openide.text.EditorSupport$Del.loadFromStreamToKit(EditorSupport.java:667)
	at
org.openide.text.CloneableEditorSupport.loadDocument(CloneableEditorSupport.java:1167)
	at
org.openide.text.CloneableEditorSupport.access$1500(CloneableEditorSupport.java:80)
	at
org.openide.text.CloneableEditorSupport$Listener.run(CloneableEditorSupport.java:1627)
	at org.openide.util.Task.run(Task.java:136)
	at
org.openide.text.CloneableEditorSupport$1.run(CloneableEditorSupport.java:348)
	at org.openide.util.Task.run(Task.java:136)
	at
org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:328)
[catch] at
org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:670)
Comment 1 Petr Nejedly 2003-11-25 14:00:27 UTC
Mila, you've seen something similar, right?
Comment 2 Petr Nejedly 2004-01-09 15:47:01 UTC
*** Issue 37786 has been marked as a duplicate of this issue. ***
Comment 3 Petr Nejedly 2004-01-13 16:44:02 UTC
*** Issue 36975 has been marked as a duplicate of this issue. ***
Comment 4 Petr Nejedly 2004-01-14 15:38:31 UTC
A bit different exception, but it seems it represents the same race
condition as issue 27773, which should be easily reproduced
by the attached example.

*** This issue has been marked as a duplicate of 27773 ***
Comment 5 pzajac 2004-02-26 16:08:22 UTC
verified