Hello. I have an application we've written which is using Crystal XI and we're experiencing a very disconcerting error.
Our application is .NET 2.0 and the XI libraries are the most recent release. I think SP4.5? We are very careful to immediately dispose of any crystal objects/resources before we move on to doing the next extract, so the amount of time the crystal libraries are in memory is limited per each iteration of the extract.
I have an open support case for this "Incident 3238538 / 2010 / ExportToStream is crashing randomly" but I don't feel like I'm getting anywhere with it and it's been ongoing for months.
Anyway, I was able to attach the DebugDiag x86 program to an affected system and capture a .dmp file. When I ran the analysis on that file, it mentions an access violation exception occurring in strncpy. (See below)
This error occurs intermittently and does not appear to be data related, as the same extract can run other times without issues, and I haven't been able to pinpoint any single cause. (which makes testing for this nearly impossible)
Apart from the application crashing, windows pops up a debugger screen, saying 'Application has encountered an error and needs to close' which a user must interact with or else the process never ends. I would like to stop this behavior.
I did a ton of reading about unmanaged exceptions on unmanaged threads and I cant find any solution for how to catch exceptions of this kind within .NET.
I've created a C++ library which creates a thread, and then generates an Access Violation in strncpy. Every attempt I've made to catch the error has been met with failure. Does anyone have any clues on what I can do to achieve this??
Type of Analysis Performed Crash Analysis
Machine Name KNOXBILLI
Operating System Windows XP Service Pack 3
Number Of Processors 2
Process ID 948
Process Image C:Program FilesPinpoint Technologies, IncCustom Solutions GroupPCR Extract for Field DataPCR Extract for Field Data.exe
System Up-Time 80 day(s) 01:12:23
Process Up-Time 00:03:54
Thread 16 - System ID 588
Entry point msvcr71!_threadstartex
Create time 1/9/2011 3:03:54 PM
Time spent in user mode 0 Days 0:0:0.0
Time spent in kernel mode 0 Days 0:0:0.46
Function Arg 1 Arg 2 Arg 3 Source
msvcr71!strncpy+53 0617fd44 08114000 00000002
U25dts+23dc 00000000 00000000 00000000
cslibu_2_1!CSLib210::CSThreadSafeDLL::needMarshaling+65 00000000 00000000 00000000
MSVCR71!STRNCPY53In PCR Extract for Field Data__PID__948__Date__01_09_2011__Time_03_03_59PM__464__Second_Chance_Exception_C0000005.dmp the assembly instruction at msvcr71!strncpy53 in C:WINDOWSsystem32msvcr71.dll from Microsoft Corporation has caused an access violation exception (0xC0000005) when trying to read from memory location 0x08114000 on thread 16
Image Name: C:WINDOWSsystem32msvcr71.dll Symbol Type: PDB
Base address: 0x7c340000 Time Stamp: Fri Feb 21 07:42:20 2003
Checksum: 0x0005f1e9 Comments:
COM DLL: False Company Name: Microsoft Corporation
ISAPIExtension: False File Description: Microsoft® C Runtime Library
ISAPIFilter: False File Version: 7.10.3052.4
Managed DLL: False Internal Name: MSVCR71.DLL
VB DLL: False Legal Copyright: © Microsoft Corporation. All rights reserved.
Loaded Image Name: msvcr71.dll Legal Trademarks:
Mapped Image Name: Original filename: MSVCR71.DLL
Module name: msvcr71 Private Build:
Single Threaded: False Product Name: Microsoft® Visual Studio .NET
Module Size: 344.00 KBytes Product Version: 7.10.3052.4
Symbol File Name: c:symcachemsvcr71.pdb630C79175C1942C099C9BC4ED019C6092msvcr71.pdb Special Build: &