diff options
Diffstat (limited to 'nx-X11/programs/Xserver/dix/dixfonts.c.X.original')
-rw-r--r-- | nx-X11/programs/Xserver/dix/dixfonts.c.X.original | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/nx-X11/programs/Xserver/dix/dixfonts.c.X.original b/nx-X11/programs/Xserver/dix/dixfonts.c.X.original index 9de998417..2c5874e8d 100644 --- a/nx-X11/programs/Xserver/dix/dixfonts.c.X.original +++ b/nx-X11/programs/Xserver/dix/dixfonts.c.X.original @@ -336,6 +336,13 @@ doOpenFont(ClientPtr client, OFclosurePtr c) err = BadFontName; goto bail; } + /* check values for firstCol, lastCol, firstRow, and lastRow */ + if (pfont->info.firstCol > pfont->info.lastCol || + pfont->info.firstRow > pfont->info.lastRow || + pfont->info.lastCol - pfont->info.firstCol > 255) { + err = AllocError; + goto bail; + } if (!pfont->fpe) pfont->fpe = fpe; pfont->refcnt++; |