Invalid memory access
#2

Somewhere in your code you are trying to do this:

pawn Код:
array[-1]
Obviously you can't access the index -1, doing so will cause undefined behavior. It wont look like the above code because that would be a compile time error. It could be more similar to this:

pawn Код:
#define INVALID_SOMETHING -1

new index = INVALID_SOMETHING;
array[ index ];
Which will be a run time error.

And fix it by checking if the variable is '-1' before using it as an array index.
Reply


Messages In This Thread
Invalid memory access - by audriuxxx - 11.05.2013, 07:42
Re: Invalid memory access - by iggy1 - 11.05.2013, 09:04

Forum Jump:


Users browsing this thread: 1 Guest(s)