access violation

Jan 5, 2013 at 9:48am
i am creating a program ...and i want to catch access violation exception when it is occurred .. how to do this?
Last edited on Jan 5, 2013 at 9:48am
Jan 6, 2013 at 6:05pm
You probably shouldn't catch access violation exceptions, they are a sign you have something wrong in your code.
Jan 12, 2013 at 12:13pm
there is some programs can do this(i noticed this while i was reversing them)
the debugger stops at a memory location which is reserved
(access violation)
but the program handled this perfectly ...did i misunderstand??
Jan 12, 2013 at 2:14pm
Maybe the program uses something like IsDebuggerPresent() API.
http://msdn.microsoft.com/en-us/library/windows/desktop/ms680345(v=vs.85).aspx
Jan 12, 2013 at 6:58pm
do you mean .... if it is sensed any debugging it will change its behavior...maybe but this is not what i asked for....it is possible to handle this(access violation) or what??
thank you all
Last edited on Jan 12, 2013 at 7:00pm
Topic archived. No new replies allowed.