Hi,

I'm using pypoppler and am wondering how to properly release a pdf file.

In particular, I would have hoped that the following python code would be
'hanging' (in the loop) with only file2.pdf open, as file1 has been del'ed.
However, an lsof shows that file1.pdf is still open. How can/should I
properly close the file1.pdf?  In my application it causes problems because
after loading a few hundred pdfs, I start getting "Too many open files"
errors.

<code>

import sys, QtPoppler, time
if __name__ == "__main__":
    d = QtPoppler.Poppler.Document.load("file1.pdf")
    del d
    d = QtPoppler.Poppler.Document.load("file2.pdf")
    time.sleep(100000)

</code>

Thank you,
David
_______________________________________________
poppler mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/poppler

Reply via email to