poppler/CharCodeToUnicode.cc |    7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

New commits:
commit 4ed53e30e735b79c46eab9d54883531c6e187b17
Author: William Bader <[email protected]>
Date:   Fri Apr 23 22:52:24 2010 +0100

    Silence some Illegal entry in bfrange block in ToUnicode CMap
    
    Fixes #27728

diff --git a/poppler/CharCodeToUnicode.cc b/poppler/CharCodeToUnicode.cc
index 5941190..80fd4c5 100644
--- a/poppler/CharCodeToUnicode.cc
+++ b/poppler/CharCodeToUnicode.cc
@@ -18,6 +18,7 @@
 // Copyright (C) 2007 Koji Otani <[email protected]>
 // Copyright (C) 2008 Michael Vrable <[email protected]>
 // Copyright (C) 2008 Vasile Gaburici <[email protected]>
+// Copyright (C) 2010 William Bader <[email protected]>
 //
 // To see a description of the changes please see the Changelog file that
 // came with your tarball or type make ChangeLog if you are building from git
@@ -307,8 +308,10 @@ void CharCodeToUnicode::parseCMap1(int (*getCharFunc)(void 
*), void *data,
          error(-1, "Illegal entry in bfrange block in ToUnicode CMap");
          break;
        }
-       if (!(n1 == 2 + nDigits && tok1[0] == '<' && tok1[n1 - 1] == '>' &&
-             n2 == 2 + nDigits && tok2[0] == '<' && tok2[n2 - 1] == '>')) {
+       if (!(((n1 == 2 + nDigits && tok1[0] == '<' && tok1[n1 - 1] == '>') ||
+              (n1 == 4 + nDigits && tok1[0] == '<' && tok1[n1 - 1] == '>' && 
tok1[1] == '0' && tok1[2] == '0')) &&
+             ((n2 == 2 + nDigits && tok2[0] == '<' && tok2[n2 - 1] == '>') ||
+              (n2 == 4 + nDigits && tok2[0] == '<' && tok2[n2 - 1] == '>' && 
tok1[1] == '0' && tok1[2] == '0')))) {
          error(-1, "Illegal entry in bfrange block in ToUnicode CMap");
          continue;
        }
_______________________________________________
poppler mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/poppler

Reply via email to