aboutsummaryrefslogtreecommitdiff
path: root/freetype/src/psaux/psconv.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2015-02-22 21:39:56 +0100
committermarha <marha@users.sourceforge.net>2015-02-22 21:39:56 +0100
commit462f18c7b25fe3e467f837647d07ab0a78aa8d2b (patch)
treefc8013c0a1bac05a1945846c1697e973f4c35013 /freetype/src/psaux/psconv.c
parent36f711ee12b6dd5184198abed3aa551efb585587 (diff)
downloadvcxsrv-462f18c7b25fe3e467f837647d07ab0a78aa8d2b.tar.gz
vcxsrv-462f18c7b25fe3e467f837647d07ab0a78aa8d2b.tar.bz2
vcxsrv-462f18c7b25fe3e467f837647d07ab0a78aa8d2b.zip
Merged origin/release (checked in because wanted to merge new stuff)
Diffstat (limited to 'freetype/src/psaux/psconv.c')
-rw-r--r--freetype/src/psaux/psconv.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/freetype/src/psaux/psconv.c b/freetype/src/psaux/psconv.c
index 9db8d67a6..36517e7ae 100644
--- a/freetype/src/psaux/psconv.c
+++ b/freetype/src/psaux/psconv.c
@@ -124,7 +124,7 @@
if ( IS_PS_SPACE( *p ) || *p OP 0x80 )
break;
- c = ft_char_table[*p & 0x7f];
+ c = ft_char_table[*p & 0x7F];
if ( c < 0 || c >= base )
break;
@@ -245,12 +245,13 @@
if ( IS_PS_SPACE( *p ) || *p OP 0x80 )
break;
- c = ft_char_table[*p & 0x7f];
+ c = ft_char_table[*p & 0x7F];
if ( c < 0 || c >= 10 )
break;
- if ( decimal < 0xCCCCCCCL )
+ /* only add digit if we don't overflow */
+ if ( divider < 0xCCCCCCCL && decimal < 0xCCCCCCCL )
{
decimal = decimal * 10 + c;
@@ -520,7 +521,7 @@
if ( *p OP 0x80 )
break;
- c = ft_char_table[*p & 0x7f];
+ c = ft_char_table[*p & 0x7F];
if ( (unsigned)c >= 16 )
break;