java.lang.IllegalArgumentException: start == end

freecol | *anonymous | 8 years ago
  1. 0

    Could not send XML to the server

    freecol | 8 years ago | *anonymous
    java.lang.IllegalArgumentException: start == end
  2. 0

    Visualizer: .css.map files are not shown

    YouTrack | 3 years ago
    java.lang.IllegalArgumentException: start > end: start=197; end=168
  3. 0

    flex: unwrapping empty block: IAE in RangeMarkerImpl

    YouTrack | 7 years ago
    java.lang.IllegalArgumentException: start > end: start=296; end=286
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    I've attached a project that reproduces this. If I have a {{ContainerRequestFilter}} abort a transaction and add a {{WWW-Authenticate}} header missing an authentication scheme (e.g., "Basic " or "OAuth ") and I try to process this response using a Jersey client, I get the following error: {noformat} Exception in thread "main" javax.ws.rs.ProcessingException: java.lang.IllegalArgumentException: invalid start or end at org.glassfish.jersey.client.ClientRuntime.invoke(ClientRuntime.java:236) at org.glassfish.jersey.client.JerseyInvocation$1.call(JerseyInvocation.java:655) at org.glassfish.jersey.client.JerseyInvocation$1.call(JerseyInvocation.java:652) at org.glassfish.jersey.internal.Errors.process(Errors.java:315) at org.glassfish.jersey.internal.Errors.process(Errors.java:297) at org.glassfish.jersey.internal.Errors.process(Errors.java:228) at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:422) at org.glassfish.jersey.client.JerseyInvocation.invoke(JerseyInvocation.java:652) at org.glassfish.jersey.client.JerseyInvocation$Builder.method(JerseyInvocation.java:387) at org.glassfish.jersey.client.JerseyInvocation$Builder.get(JerseyInvocation.java:291) at org.glassfish.test.TestApp.main(TestApp.java:20) Caused by: java.lang.RuntimeException: java.lang.IllegalArgumentException: invalid start or end at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1137) at sun.net.www.protocol.http.HttpURLConnection.getHeaderField(HttpURLConnection.java:2338) at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:388) at org.glassfish.jersey.client.HttpUrlConnector._apply(HttpUrlConnector.java:276) at org.glassfish.jersey.client.HttpUrlConnector.apply(HttpUrlConnector.java:182) at org.glassfish.jersey.client.ClientRuntime.invoke(ClientRuntime.java:227) ... 10 more Caused by: java.lang.IllegalArgumentException: invalid start or end at sun.net.www.HeaderParser.subsequence(HeaderParser.java:58) at sun.net.www.protocol.http.AuthenticationHeader.parse(AuthenticationHeader.java:155) at sun.net.www.protocol.http.AuthenticationHeader.<init>(AuthenticationHeader.java:119) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1261) at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:379) ... 13 more {noformat} It's not a problem with the headers, as they seem well-formed (when I hit it using Live HTTP Headers in Firefox): {noformat} http://localhost:8080/ GET / HTTP/1.1 Host: localhost:8080 User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:26.0) Gecko/20100101 Firefox/26.0 Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 Accept-Language: en-US,en;q=0.5 Accept-Encoding: gzip, deflate Connection: keep-alive HTTP/1.1 401 Unauthorized WWW-Authenticate: oauth_problem=token_rejected Date: Fri, 17 Jan 2014 21:12:33 GMT Content-Length: 0 {noformat} What's interesting is that if I set this header in a {{ContainerResponseFilter}}, the client processes it just fine. You can exercise this problem using the {{org.glassfish.test.TestApp}} application in the Maven project attached to this bug.

    Java.net JIRA | 3 years ago | jrh3k5
    javax.ws.rs.ProcessingException: java.lang.IllegalArgumentException: invalid start or end

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.IllegalArgumentException

      start == end

      at net.sf.freecol.common.model.Map.findPath()
    2. net.sf.freecol
      ConnectController$1$1.run
      1. net.sf.freecol.common.model.Map.findPath(Map.java:343)
      2. net.sf.freecol.common.model.Map.findPath(Map.java:223)
      3. net.sf.freecol.client.control.InGameController.moveToDestination(InGameController.java:700)
      4. net.sf.freecol.client.control.InGameController.nextActiveUnit(InGameController.java:3590)
      5. net.sf.freecol.client.control.InGameController.nextActiveUnit(InGameController.java:3531)
      6. net.sf.freecol.client.control.InGameController.setCurrentPlayer(InGameController.java:310)
      7. net.sf.freecol.client.control.ConnectController.login(ConnectController.java:265)
      8. net.sf.freecol.client.control.ConnectController.access$100(ConnectController.java:65)
      9. net.sf.freecol.client.control.ConnectController$1$1.run(ConnectController.java:413)
      9 frames
    3. Java RT
      EventQueue.dispatchEvent
      1. java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:226)
      2. java.awt.EventQueue.dispatchEvent(EventQueue.java:602)
      2 frames