Menu

Tess4j Dispose method leaking handles

2021-01-06
2021-02-09
  • Jitin Jindal

    Jitin Jindal - 2021-01-06

    Hi Tea,

    I am using Tess4j 4.x version and whenever tessAPI is called for doOCR.
    dispose() method is leaking 4 handles everytime.

    protected void dispose() {
        if (api != null && handle != null) {
            api.TessBaseAPIDelete(handle);
        }
    }
    
    Handle count is getting increased for each request.
    
    Is there any known issue with Tess4j 4.X as this issue was not there in tess4j 3.X.
    
     
  • Jitin Jindal

    Jitin Jindal - 2021-02-09

    Can anyone help over here?

    api.TessBaseAPIInit1(***) creating 4 handles for every call which are not released by tessBaseAPIDelete()

     

Log in to post a comment.