Page 1 of 1

Unhandled Exception: System.AccessViolationException: Attempted to read or write protected memory

Posted: Thu 10 May 2007 14:53
by kevinherring
Hi

I am getting the following exception:
Unhandled Exception: System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
at OciDynamicType.nativea(HandleRef , Int32 )
at OciDynamicType.a(HandleRef , Int32 )
at CoreLab.Oracle.at.a()
at CoreLab.Oracle.a6.q()
at CoreLab.Oracle.OracleCursor.Finalize()

However, the exception only occurs on a select few clients machines, and it happens at seemly random intervals. The only thing that I can establish is that the longer my program is in use, the more likely it is to happen. We are using version 3.55.19 of the .net 2.0 driver. I am using connection pooling and threading but I have checked my code and I am cleaning up after myself properly. The only thing that I can think is that the clients that are getting the crash have 8.1 oracle clients set as default, which I am in the process of getting upgraded. They are connecting to a 9.2 database.

It would appear from google that other people have had this exception but there doesnt seem to be any definitive answer to it. Some people seem to have had the problem with the official oracle drivers.

I am at a bit of a loss, so I was wondering if you had ever seen it before?

Thanks
Kevin

Posted: Fri 11 May 2007 07:14
by Alexey
When you are likely to get this error?

Posted: Mon 04 Jun 2007 08:58
by kevinherring
its hard to tell, and not consistant, but it seems to happen when populating a dataset or using a reader.

However it isnt an exception that I can catch.

Posted: Mon 04 Jun 2007 11:57
by Alexey
Without a sample it's very hard to say why that problem occurs.

Posted: Mon 04 Jun 2007 11:58
by kevinherring
yes of course, I am having a similar problem as I cant reproduce it on our developer or test machines. Just wondered if you had seen anything like it before.

Posted: Mon 04 Jun 2007 12:03
by Alexey
I've seen this. But that problem has already been fixed ages ago.
Try to use a newer version of Oracle client.