summaryrefslogtreecommitdiff
path: root/src/freetype2/pfr/pfrdrivr.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/freetype2/pfr/pfrdrivr.c')
-rw-r--r--src/freetype2/pfr/pfrdrivr.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/freetype2/pfr/pfrdrivr.c b/src/freetype2/pfr/pfrdrivr.c
index 4020672..15cca98 100644
--- a/src/freetype2/pfr/pfrdrivr.c
+++ b/src/freetype2/pfr/pfrdrivr.c
@@ -4,7 +4,7 @@
/* */
/* FreeType PFR driver interface (body). */
/* */
-/* Copyright 2002, 2003, 2004, 2006 by */
+/* Copyright 2002, 2003, 2004, 2006, 2008 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -66,10 +66,16 @@
FT_Pos *anadvance )
{
PFR_Face face = (PFR_Face)pfrface;
- FT_Error error = PFR_Err_Bad_Argument;
+ FT_Error error = PFR_Err_Invalid_Argument;
*anadvance = 0;
+
+ if ( !gindex )
+ goto Exit;
+
+ gindex--;
+
if ( face )
{
PFR_PhyFont phys = &face->phy_font;
@@ -82,6 +88,7 @@
}
}
+ Exit:
return error;
}