diff options
Diffstat (limited to 'nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original')
-rw-r--r-- | nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original index 6dfff3776..b431796be 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original @@ -437,6 +437,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++; |