locked
System.AccessViolationException - Attempted to read or write protected memory

    Question

  • Hi! Today I ran into this kind of problem for the first time. I installed my app, which is server/client thing on a computer with WinXP(forgot to check which service pack).

    Server is Windows Service that accepts connections via remoting. I get this error on the server side each time I try to connect to it with the client (on the same computer).

    System.AccessViolationException

    Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

    at System.Net.UnsafeNclNativeMethods.OSSOCK.WSAGetOverlappedResult(SaveCloseSocket socketHandle, IntPtr overlapped, UInt32& bytesTransferred, Boolean wait, IntPtr ignored)

    at System.Net.Sockets.BaseOverlappedAsyncResult.CompletionPortCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* nativeOverlapped)

    at System.Threading._IOCompletionCallback.PerformIOCompletionCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* pOVERLAP)

     

    Any ideas? This seems more than just a simple problem.. As I said.. This is the first time I get this (I installed the thing on many boxes already).. So maybe it is just an unfortunate thing.. Maybe Windows is corrupt?

    oh maybe I should reinstall .NET framework? true... I have to check if its beta.. forgot to do it.. but you can still help me think of other things that may be wrong until I get back to that computer and check SP and .NET Runtime version... thank you

     

    David

    Monday, May 8, 2006 12:27 PM

Answers

  • For anyone having the same type of problem, read this:

    http://www.developersdex.com/vb/message.asp?p=2923&ID=%3C349BC236-B0C4-4A42-A908-67C4012A53AD%40microsoft.com%3E

    http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=168193&SiteID=1

    So one of these programs are probably causing the error: netlimiter, nod32, panda
    Wednesday, May 31, 2006 7:16 AM

All replies

  • For anyone having the same type of problem, read this:

    http://www.developersdex.com/vb/message.asp?p=2923&ID=%3C349BC236-B0C4-4A42-A908-67C4012A53AD%40microsoft.com%3E

    http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=168193&SiteID=1

    So one of these programs are probably causing the error: netlimiter, nod32, panda
    Wednesday, May 31, 2006 7:16 AM
  • Thanks for posting the links
    Wednesday, May 30, 2007 4:48 AM
  • I'd like to add another application to the list above that can cause the AccessViolationException.

    PGPDesktop

    Once I uninstalled PGPDesktop, everything worked fine.

    I was able to determine PGP was the problem by noticing an Application Error in the windows event log. The error referenced something called pgplsp.dll.
    Wednesday, June 13, 2007 6:40 PM
  • Hi,

    I also face the same problem like you. The error description as follow:

     

    System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

     

    This occured when i run the ETL when i remote to client server.

     

    Any ideas?

     

    Thanks

     

    Kwee Yen

    Friday, September 28, 2007 6:00 AM