Ensure string is hex before passing to hexdec
Ensure string is hex before passing to hexdec

... where the source is not known to be a hex value

Addresses #2003

BrunoDeBarros/dompdf,dompdf/dompdf,dompdf/dompdf,BrunoDeBarros/dompdf