Added extra checks to avoid possible data corruption as per coverity report (#107)
Added extra checks to avoid possible data corruption as per coverity report (#107)


AndreRenaud/PDFGen,AndreRenaud/PDFGen,AndreRenaud/PDFGen