Bufixes. Added version that works with the external pdftotext tool