texlive-2009-CVE-2010-0827.patch 822 B

12345678910111213141516171819202122232425262728
  1. ---
  2. texk/dvipsk/virtualfont.c | 6 +++++-
  3. 1 file changed, 5 insertions(+), 1 deletion(-)
  4. Index: texlive-bin-2009/texk/dvipsk/virtualfont.c
  5. ===================================================================
  6. --- texlive-bin-2009.orig/texk/dvipsk/virtualfont.c 2010-05-01 02:12:57.000000000 +0900
  7. +++ texlive-bin-2009/texk/dvipsk/virtualfont.c 2010-05-01 02:16:19.000000000 +0900
  8. @@ -36,7 +36,7 @@
  9. * Subroutine vfbyte returns the next byte.
  10. */
  11. static FILE *vffile ;
  12. -static char name[50] ;
  13. +static char name[500] ;
  14. void
  15. badvf(char *s)
  16. {
  17. @@ -93,6 +93,10 @@
  18. if (*d==0)
  19. d = vfpath ;
  20. #endif
  21. + if (strlen(n) + 5 >= sizeof (name)) {
  22. + /* 5 for vf() + null */
  23. + error("! VF file name too long in vfopen") ;
  24. + }
  25. #ifdef MVSXA /* IBM: MVS/XA */
  26. (void)sprintf(name, "vf(%s)", n) ;
  27. #else