Tolerate poorly formatted pdfs