Skip to content
This repository has been archived by the owner on Jul 24, 2021. It is now read-only.

Index out of bounds exception in java console #111

Closed
openstreetmap-trac opened this issue Jul 23, 2021 · 5 comments
Closed

Index out of bounds exception in java console #111

openstreetmap-trac opened this issue Jul 23, 2021 · 5 comments

Comments

@openstreetmap-trac
Copy link

Reporter: erik[at]tiq.com
[Submitted to the original trac issue database at 11.37am, Tuesday, 27th December 2005]

Not reproduceable yet.

Exception in thread "Thread-305" java.lang.ArrayIndexOutOfBoundsException: 0 >= 0
at java.util.Vector.elementAt(Unknown Source)
at org.openstreetmap.client.Tile.getEle(Tile.java:361)
at org.openstreetmap.client.ImFetch.run(Tile.java:437)

This is the log entries:

Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=16.929931640625,61.7419302246182,16.94091796875,61.74453081889597&width=256&height=128
adding image 1541,14389
mousePressed in ModeManager with currentMode=org.openstreetmap.processing.OSMApplet$LineMode@aa2ef2 and overButton=false
Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=16.94091796875,61.7289239586037,16.951904296875,61.73152565113397&width=256&height=128
adding image 1542,14384
Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=16.94091796875,61.7289239586037,16.951904296875,61.73152565113397&width=256&height=128
adding image 1542,14384
Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=16.94091796875,61.73152565113397,16.951904296875,61.73412712398737&width=256&height=128
adding image 1542,14385
Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=16.94091796875,61.73152565113397,16.951904296875,61.73412712398737&width=256&height=128
adding image 1542,14385
Exception in thread "Thread-305" java.lang.ArrayIndexOutOfBoundsException: 0 >= 0
at java.util.Vector.elementAt(Unknown Source)
at org.openstreetmap.client.Tile.getEle(Tile.java:361)
at org.openstreetmap.client.ImFetch.run(Tile.java:437)
getting nodes and lines
trying url: http://www.openstreetmap.org/api/0.2/map?bbox=16.910602569580078,61.73166151838643,16.940643310546875,61.74182223008769
2005-dec-28 22:36:56 org.apache.commons.httpclient.auth.AuthChallengeProcessor selectAuthScheme
INFO: basic authentication scheme selected
GPX parser started...
Start of Document
End of Document

@openstreetmap-trac
Copy link
Author

Author: erik[at]tiq.com
[Added to the original trac issue at 9.43pm, Wednesday, 28th December 2005]

I think it's impossibleto use the "create segment" tool when this happens.

@openstreetmap-trac
Copy link
Author

Author: 80n80n[at]gmail.com
[Added to the original trac issue at 8.47pm, Friday, 30th December 2005]

I got a similar error. The applet just stops responding but is indistinguishable from a slow server so you can wait around for a long time before deciding that you need to reload the applet. Hence I've increased the priority a bit.


Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=-2.955322265625,51.034485632974125,-2.9443359375,51.037939894299356&width=256&height=128
getting nodes and lines
trying url: http://www.openstreetmap.org/api/0.2/map?bbox=-2.9868006706237797,51.0391213348809,-2.9567599296569824,51.0526117317383
adding image -269,10839
Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=-2.955322265625,51.034485632974125,-2.9443359375,51.037939894299356&width=256&height=128
adding image -269,10839
Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=-2.955322265625,51.037939894299356,-2.9443359375,51.04139389812637&width=256&height=128
adding image -269,10840
Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=-2.955322265625,51.04139389812637,-2.9443359375,51.04484764446179&width=256&height=128
adding image -269,10841
Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=-2.955322265625,51.04484764446179,-2.9443359375,51.04830113331224&width=256&height=128
mousePressed in ModeManager with currentMode=null and overButton=false
adding image -269,10842
Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=-2.955322265625,51.04830113331224,-2.9443359375,51.05175436468443&width=256&height=128
30-Dec-2005 19:48:24 org.apache.commons.httpclient.auth.AuthChallengeProcessor selectAuthScheme
INFO: basic authentication scheme selected
GPX parser started...
Start of Document
End of Document
adding image -269,10843
Trying to download image http://www.openstreetmap.org/tile/0.1/wms?map=/usr/lib/cgi-bin/steve/wms.map&service=WMS&WMTVER=1.0.0&REQUEST=map&STYLES=&TRANSPARENT=TRUE&LAYERS=landsat,gpx&bbox=-2.955322265625,51.05175436468443,-2.9443359375,51.055207338584964&width=256&height=128
adding image -269,10844
Exception in thread "Thread-420" java.lang.ArrayIndexOutOfBoundsException: 0 >= 0
at java.util.Vector.elementAt(Unknown Source)
at org.openstreetmap.client.Tile.getEle(Tile.java:361)
at org.openstreetmap.client.ImFetch.run(Tile.java:437)
getting nodes and lines
trying url: http://www.openstreetmap.org/api/0.2/map?bbox=-2.9874014854431157,51.03129510442612,-2.9573607444763184,51.04478778009968
30-Dec-2005 19:49:58 org.apache.commons.httpclient.auth.AuthChallengeProcessor selectAuthScheme
INFO: basic authentication scheme selected
GPX parser started...
Start of Document
End of Document

@openstreetmap-trac
Copy link
Author

Author: immanuel.scholz[at]gmx.de
[Added to the original trac issue at 12.31pm, Tuesday, 28th February 2006]

Probably a synchronisation problem.

The fetch thread does not lock the vector, so could it be possible, that removeUnusedTiles is called by drag which will remove the last element in the vector exactly between the fetch thread checks for empty vector and the call to getEle with an empty imv-vector?

Imi.

@openstreetmap-trac
Copy link
Author

Author: writetodan[at]yahoo.com
[Added to the original trac issue at 9.46am, Saturday, 17th February 2007]

Almost certainly due to unsafe thread access.

Am just testing some fixes now.

@openstreetmap-trac
Copy link
Author

Author: writetodan[at]yahoo.com
[Added to the original trac issue at 8.52pm, Wednesday, 14th March 2007]

fix deployed to www

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant