Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Firstly, an IndexOutOfBoundsException cannot be thrown on an array that hasn't been declared yet.</p> <p>The error is happening in release mode without the debugger attached. This is good to know. Keep in mind that there are major optimizations done by Visual Studio when your code is compiled in release <em>and</em> not attached to a debugger. This leads me to my main point.</p> <h2>YOU ARE BEING MISLED BY THE STACK TRACE</h2> <p>I confirmed this myself, by purposely trying to access an element outside of the array. The stack trace said the error happened on line 36, which for me is: <code>return list;</code> The actual error that I caused, was inserted on line 31.</p> <p>I doubt the stack trace isn't lying about what function the exception is happening, though. But I would say that the code throwing the exception is probably not the code you see in Visual Studio.</p> <ol> <li><p>Does the issue happen when you run it in Release mode with the debugger attached?</p></li> <li><p>Open the code in a decompiler, like <a href="http://www.telerik.com/products/decompiler.aspx" rel="nofollow">this one</a>. If you browsed to the method you have above, does the source code match (more or less, a decompiler isn't perfect).</p></li> </ol> <p>EDIT:</p> <p>So the code seems to be the same. Either way, the error that you are getting is not happening at the line the stack trace is telling you. There's nothing I can do to help you at this point, since I don't have access to the offending binary.</p> <p>My suggestion: When the application crashes, use Task Manager to save a dump of the program's memory. (Alternatively, you can use <a href="http://support.microsoft.com/kb/286350" rel="nofollow">AdPlus</a> or <a href="http://technet.microsoft.com/en-us/sysinternals/dd996900" rel="nofollow">ProcDump</a>, to do it automatically when it crashes). Use WinDbg to open the dump and view the memory, stack trace, and even the jitted methods to try and determine where it actually happened.</p> <p>Other than that, there's not much you can get from anyone else here on StackOverflow. Bugs like this are a pain, and unfortunately happen every once and a while.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload