Community

EXCEPTION_ACCESS_VIOLATION in PdfTools.APDFLWrapper.dll+0x2fe5

Hello

We are trying to use the ABBY FineReader engine 12 with Java wrapper, but we encounter the following error:

 

#

# A fatal error has been detected by the Java Runtime Environment:

#

#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00007ffd645f2fe5, pid=18084, tid=20196

#

# JRE version: OpenJDK Runtime Environment (11.0.4+10) (build 11.0.4+10-b304.69)

# Java VM: OpenJDK 64-Bit Server VM (11.0.4+10-b304.69, mixed mode, tiered, compressed oops, g1 gc, windows-amd64)

# Problematic frame:

# C  [PdfTools.APDFLWrapper.dll+0x2fe5]

 

Code:

IFRDocument document = engine.CreateFRDocument();
try {
byte[] fileContent = Resources.toByteArray(Resources.getResource("input.pdf"));
IImageDocument imageDocument = engine.OpenImageFileFromMemory(fileContent, null, null, null);
document.AddImageDocument(imageDocument);
document.Process(null);
document.Export("d:\\output.pdf", FileExportFormatEnum.FEF_PDF, null);
} finally {
// Close document
if (document != null) {
document.Close();
}
}

0

Comments

2 comments

  • Avatar
    eXsio

    P.S. 

    Same errors on different JVM: JRE version: Java(TM) SE Runtime Environment (8.0_191-b26) (build 1.8.0_191-b26)

    0
    Comment actions Permalink
  • Avatar
    eXsio

    It seems that the cause was lack of adding 

    Engine.DeinitializeEngine();

    at the end of processing

    0
    Comment actions Permalink

Please sign in to leave a comment.