S
S
Student20022021-04-29 19:50:50
.NET
Student2002, 2021-04-29 19:50:50

On another PC, the software crashes without exception, how to find the cause?

Hello, there is software.
Works in multithreading and uses tesseract (perhaps this is important)
On my PC, the software does not crash and works fine
. On the PC of a friend, the software works for about an hour and crashes. Moreover, no error messages appear (I left it to work on my own for more than 12 hours and everything is fine)
That's what was in the Windows logs


Application: TesseractCombine.exe
Platform version: v4.0.30319
Description. The process was terminated due to an unhandled exception.
Exception Details: System.AccessViolationException
at InteropRuntimeImplementer.TessApiSignaturesInstance.TessApiSignaturesImplementation.BaseApiRecognize(System.Runtime.InteropServices.HandleRef, System.Runtime.InteropServices.HandleRef)
at Tesseract.Page.Recognize()
at Tesseract.Page.GractetText()
at Tesseract .FormMain.GetText(Byte[])
to TesseractCombine.FormMain.text_Lightshot(System.String, System.String, Int32)
to TesseractCombine.FormMain+d__31.MoveNext()
at System.Runtime.CompilerServices.AsyncMethodBuilderCore+MoveNextRunner.InvokeMoveNext(System.Object)
at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext .Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
to System.Runtime.CompilerServices.AsyncMethodBuilderCore+MoveNextRunner.Run()

[19:42:23] Chu Feng: to System.Threading. Tasks.AwaitTaskContinuation.RunOrScheduleAction(System.Action, Boolean, System.Threading.Tasks.Task ByRef)
to System.Threading.Tasks.Task.FinishContinuations()
to System.Threading.Tasks.Task.FinishStageThree()
at System.Threading.Tasks.Task.FinishStageTwo()
at System.Threading.Tasks.Task.Finish(Boolean)
at System.Threading.Tasks.Task.ExecuteWithThreadLocal(System.Threading.Tasks.Task ByRef)
at System.Threading. Tasks.Task.ExecuteEntry(Boolean)
to System.Threading.Tasks.Task.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
to System.Threading.ThreadPoolWorkQueue.Dispatch()
to System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()

How can I catch the moment where the crash occurs on the PC of a friend, or at least call it from me so that the studio highlights the piece when the crash occurs where?
Perhaps important: a familiar PC is much more powerful than mine and the software works much faster there.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
B
BasiC2k, 2021-04-29
@BasiC2k

Check if the target PC has VC_redist.x64.exe and VC_redist.x86.exe installed

R
Roman Mirilaczvili, 2021-04-29
@2ord

The exception note System.AccessViolationExceptionsays

An access violation occurs in unmanaged or unsafe code when the code attempts to read or write to memory that has not been allocated, or to which it does not have access. This usually occurs because a pointer has a bad value.
which may indicate a problem in the binding to Tesseract. Most likely, it is not designed for multi-threaded use.
I would add logs around Tesseract calls and not only there.

N
Ne4to, 2021-04-30
@Ne4to

you need to configure the collection of a memory dump in case of a fall
, you can do it manually through the registry - https://docs.microsoft.com/en-us/windows/win32/wer...
or through procdump64 from the sysinternals package ,
procdump64 -ma -i C:\dbg\CrashDumps
the resulting dump can be opened in the studio or through WinDbg

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question