What can be the reason of the following exception in ASP.NET application under IIS 7?
It is an unhandled exception that restarts the whole application.
Exception: System.AccessViolationException
Message: Attempted to read or write protected memory. This is often an indication that other memory has been corrupted.
StackTrace:
in Sy...
I'm trying to do:
try{
int * i = NULL;
*i = 3;
}catch(Exception &Err){
ShowMessage(Err.Message);
}
I though that this should catch access violation exception and handle it by displaying an error message.
But for some reason I get simple 'Access Violation' message instead of full one: 'Access Violation XXX in module YYY. W...
I have to load modules as dlls dynamically at runtime as they are not known ahead of time, just that they conform to a class interface. What I noticed is that after I catch an exception thrown by the dll (in the main program in the main thread), the right destructors are called and the modules destroyed and dll's unloaded, but then as t...
First Question:
Is the following routine a correct implementation of an Indy 9 IdTcpServer.OnExecute routine?
procedure TMyConnServer.ServerExecute(AContext: TIdPeerThread);
var
buffSize: integer;
str: string;
begin
AContext.Connection.ReadFromStack(True, 600, False);
buffSize := AContext.Connection.InputBuffer.Size;
if ...
I apologize in advance for a newbie question, but why do I get "Access violation" error with the code below (on the "Create(SelectorForm);" line)? I tried using the main form as the owner, but it didn't make any difference.
var
SelectorForm: TSelectorForm;
ArrayOfImages: Array [1..10] of TImage;
implementation
procedure TSelectorF...
Hello,
I have for the most part successfully embedded firefox/xulrunner into our c# application, but it is not without troubles. Once in a great while a AccessViolationException will be thrown which I believe is caused by the GC moving a managed object in memory and the unmanaged xpcom attempts to use it after it has been moved. For exam...
We are having nondeterministic System.AccessViolationException thrown from native code. It's hard to reproduce it, but sometimes it happens. I'm not sure if I can "just debug it" since the time needed for access violation is about 2 hours and there is no guarantees that access violation will happen.
The native library is used by managed...
Hi,
I'm getting the following exception when I run my application in Release mode from Visual C++.
Unhandled Exception:
System.AccessViolationException:
Attempted to read or write protected
memory. This is often an indication
that other memory is corrupt. at
_cexit() at .LanguageSupport._UninitializeDefaultDomain(Vo...
Hi all,
I asked a similar question a couple of days ago, but I'm looking for more insight. I'm getting an AccessViolationException when I add a string to my program:
Unhandled Exception: System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
at _cexit(...
I have a weird problem trying to use a DLL written in C++ from a Delphi (Turbo Delphi 2006) program.
When I run the Delphi program (see below) from the command line, everything works fine. Also, when I run it from the Delphi environment without debugging (CTRL+SHIFT+F9), everything is fine. However, when running it with debugging (F9), ...
I've been trying to figure out for nearly a week now how to call StgCreateStorageEx in C#, and all I've got to show for it is an AccessViolationException and a headache.
I'm not even sure how I should declare the function. I've seen a zillion websites declare it a zillion different ways. But this is what I currently have:
[DllImport(...
Getting an AccessViolationException when calling ToString() on my MemberInfo.
I suspect something is holding onto the Type information on one of my methods parameters and causing the error, could this be possible?
What usually causes the AccessViolationExpection?
I'm getting looping through the Public Static methods a Type and am gettin...
We have developed an application that has intensive thread use (+-50 threads) in Vb.Net. From time to time we get an AccessViolationException at a random thread while it is doing a Thread.Sleep().
As far as we know we're no executing unsafe code as all our code is managed. We're using DevExpress controls but we don't know if they have u...
Hello!
I am just testing and trying to learn how assembler works with C. So i was browsing around some tutorials and i found this:
__asm
{
mov ax,0B800h //startaddress for the screen memory (in textmode)
mov es,ax //add the startaddress to es
xor di,di //reset di (start at the beginnin...
Howdy all -
Here is the prototype for a C function that resides in a DLL:
extern "C" void__stdcall__declspec(dllexport) ReturnPulse(double*,double*,double*,double*,double*);
In another thread, I asked about how to properly create and send the necessary arguments to this function.
Here is the thread:
http://stackoverflow.com/question...
So I have a native 3rd party C++ code base I am working with (.lib and .hpp files) that I used to build a wrapper in C++/CLI for eventual use in C#.
I've run into a particular problem when switching from Debug to Release mode, in that I get an Access Violation Exception when a callback's code returns.
The code from the original hpp...
I've been struggling for weeks with relentless errors thrown either by VS2008 or MySQL Connector/NET.
These errors appear sort of randomly while messing with Visual Studio's Dataset Designer and, as soon as it starts, it won't stop; It even prevents from saving the XSD file. A pop-up shows:
Attempted to read or write protected memor...
I have a website that i've been working on for about a year now.
Recently, it's started throwing System.AccessViolationException every now and then, in my dev machine, mostly, when I was away from the machine...
I haven't changed anything on the server code in weeks, since I've been working 100% on the Javascript part, and this error st...
Hi,
I have a bug somewhere that is causing my app to just vanish without an error message or something like that. The app just dissapears from the screen and it's no longer listed on the Task Manager.
The app is a C++Builder app (CBuilder2007), and I have tried everything I have think of to try to catch this error. It happens very very...
** Sorry for the confusion regarding numCars in the original post. I modified the code to be consistent with the original ****
The following academic program is a simplified version of the original problem but it focuses on the issue that I have yet to resolve. There are 2 classes and a main method to this problem and the 2 classes cons...