Modify

Opened 15 years ago

Closed 15 years ago

#5153 closed defect (fixed)

Exception when fixing duplicate ways in validator

Reported by: bilbo Owned by: bilbo
Priority: normal Milestone:
Component: Core validator Version: latest
Keywords: Cc:

Description

I clicked on "duplicate ways" in validator and pressed "fix". This exception popped up:

Build-Date: 2010-06-17 17:08:17
Revision: 3334
Is-Local-Build: true

Identification: JOSM/1.5 (3334 SVN en)
Memory Usage: 215 MB / 533 MB (61 MB allocated, but free)
Java version: 1.6.0_20, Sun Microsystems Inc., Java HotSpot(TM) 64-Bit Server VM
Operating system: Linux
Dataset consistency test: No problems found

Plugin: buildings_tools (21706)
Plugin: graphview (21706)
Plugin: measurement (21706)
Plugin: multipoly (21706)
Plugin: openstreetbugs (21706)
Plugin: remotecontrol (21706)
Plugin: reverter (21745)
Plugin: terracer2 (${version.entry.commit.revision})
Plugin: tracer (20251)
Plugin: undelete (21186)
Plugin: validator (21667)
Plugin: wmsplugin (21667)

java.lang.NullPointerException
	at javax.swing.BufferStrategyPaintManager.flushAccumulatedRegion(BufferStrategyPaintManager.java:399)
	at javax.swing.BufferStrategyPaintManager.copyArea(BufferStrategyPaintManager.java:327)
	at javax.swing.RepaintManager.copyArea(RepaintManager.java:1239)
	at javax.swing.JViewport.blitDoubleBuffered(JViewport.java:1604)
	at javax.swing.JViewport.windowBlitPaint(JViewport.java:1573)
	at javax.swing.JViewport.setViewPosition(JViewport.java:1118)
	at javax.swing.JViewport.scrollRectToVisible(JViewport.java:415)
	at javax.swing.JComponent.scrollRectToVisible(JComponent.java:3065)
	at javax.swing.JComponent.scrollRectToVisible(JComponent.java:3065)
	at javax.swing.JTree.scrollPathToVisible(JTree.java:2095)
	at javax.swing.JTree.scrollRowToVisible(JTree.java:2113)
	at org.openstreetmap.josm.gui.dialogs.CommandStackDialog.buildTrees(CommandStackDialog.java:246)
	at org.openstreetmap.josm.gui.dialogs.CommandStackDialog.commandChanged(CommandStackDialog.java:306)
	at org.openstreetmap.josm.data.UndoRedoHandler.fireCommandsChanged(UndoRedoHandler.java:121)
	at org.openstreetmap.josm.data.UndoRedoHandler.afterAdd(UndoRedoHandler.java:49)
	at org.openstreetmap.josm.data.UndoRedoHandler.add(UndoRedoHandler.java:60)
	at org.openstreetmap.josm.plugins.validator.tests.DuplicateWay.fixError(DuplicateWay.java:169)
	at org.openstreetmap.josm.plugins.validator.TestError.getFix(TestError.java:226)
	at org.openstreetmap.josm.plugins.validator.ValidatorDialog$FixTask.realRun(ValidatorDialog.java:491)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.doRealRun(PleaseWaitRunnable.java:83)
	at org.openstreetmap.josm.gui.PleaseWaitRunnable.run(PleaseWaitRunnable.java:129)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:619)

Attachments (1)

validator-dupcrash.patch (725 bytes ) - added by bilbo 15 years ago.
Patch to fix the bug

Download all attachments as: .zip

Change History (6)

comment:1 by stoecker, 15 years ago

Owner: changed from team to bilbo
Status: newneedinfo

Can you make this reproducable?

comment:2 by bilbo, 15 years ago

The bug seem to appear randomly and relatively rarely (perhaps few times a day), so I am not sure if I can reproduce it. I'll try next time if I see it.

comment:3 by stoecker, 15 years ago

Resolution: irreproducible
Status: needinfoclosed

comment:4 by bilbo, 15 years ago

Resolution: unreproducable
Status: closedreopened

I found a cause - the DuplicateWays part of validator used older method of adding the results:
Main.main.undoRedo.add(....

thus causing extra redrawing and probably these bugs, as a result from race conditions from validatror trying to fix the data that are being displayed.

I fixed the bug and I am attaching the patch.

by bilbo, 15 years ago

Attachment: validator-dupcrash.patch added

Patch to fix the bug

comment:5 by bastiK, 15 years ago

Resolution: fixed
Status: reopenedclosed

(In [o22714])

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain bilbo.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.