From: kramm Date: Mon, 19 Nov 2001 15:36:12 +0000 (+0000) Subject: copy with too big character indicies in getCharName. X-Git-Tag: release-0-1-2~6 X-Git-Url: http://git.asbjorn.it/?a=commitdiff_plain;h=1267403bc893407a1031042776675244afaae379;hp=2f2c12340920b5764b1a697ea5f21318eb8b5f03;p=swftools.git copy with too big character indicies in getCharName. --- diff --git a/pdf2swf/xpdf/FontEncoding.h b/pdf2swf/xpdf/FontEncoding.h index 7c81153..10e6fce 100644 --- a/pdf2swf/xpdf/FontEncoding.h +++ b/pdf2swf/xpdf/FontEncoding.h @@ -43,7 +43,7 @@ public: void addChar(int code, char *name); // Return the character name associated with . - char *getCharName(int code) { return encoding[code]; } + char *getCharName(int code) { return code>=size?0:encoding[code]; } // Return the code associated with . int getCharCode(char *name);