Blob Blame History Raw
diff -up texlive-20180414/source/texk/dvipsk/writet1.c.CVE-2018-17407 texlive-20180414/source/texk/dvipsk/writet1.c
--- texlive-20180414/source/texk/dvipsk/writet1.c.CVE-2018-17407	2018-09-26 08:37:29.964110003 +0100
+++ texlive-20180414/source/texk/dvipsk/writet1.c	2018-09-26 08:38:06.454784619 +0100
@@ -1449,7 +1449,9 @@ static void t1_check_unusual_charstring(
         *(strend(t1_buf_array) - 1) = ' ';
 
         t1_getline();
+        alloc_array(t1_buf, strlen(t1_line_array) + strlen(t1_buf_array) + 1, T1_BUF_SIZE);
         strcat(t1_buf_array, t1_line_array);
+        alloc_array(t1_line, strlen(t1_buf_array) + 1, T1_BUF_SIZE);
         strcpy(t1_line_array, t1_buf_array);
         t1_line_ptr = eol(t1_line_array);
     }
diff -up texlive-20180414/source/texk/web2c/luatexdir/font/writet1.w.CVE-2018-17407 texlive-20180414/source/texk/web2c/luatexdir/font/writet1.w
--- texlive-20180414/source/texk/web2c/luatexdir/font/writet1.w.CVE-2018-17407	2018-09-26 08:34:35.340880599 +0100
+++ texlive-20180414/source/texk/web2c/luatexdir/font/writet1.w	2018-09-26 08:35:45.992187544 +0100
@@ -1624,8 +1624,10 @@ static void t1_check_unusual_charstring(
     /* if no number follows "/CharStrings", let's read the next line */
     if (sscanf(p, "%i", &i) != 1) {
         strcpy(t1_buf_array, t1_line_array);
+        alloc_array(t1_buf, strlen(t1_line_array) + strlen(t1_buf_array) + 1, T1_BUF_SIZE);
         t1_getline();
         strcat(t1_buf_array, t1_line_array);
+        alloc_array(t1_line, strlen(t1_buf_array) + 1, T1_BUF_SIZE);
         strcpy(t1_line_array, t1_buf_array);
         t1_line_ptr = eol(t1_line_array);
     }
diff -up texlive-20180414/source/texk/web2c/pdftexdir/writet1.c.CVE-2018-17407 texlive-20180414/source/texk/web2c/pdftexdir/writet1.c
--- texlive-20180414/source/texk/web2c/pdftexdir/writet1.c.CVE-2018-17407	2018-09-26 08:36:06.382564736 +0100
+++ texlive-20180414/source/texk/web2c/pdftexdir/writet1.c	2018-09-26 08:37:12.213781850 +0100
@@ -1598,7 +1598,9 @@ static void t1_check_unusual_charstring(
         *(strend(t1_buf_array) - 1) = ' ';
 
         t1_getline();
+        alloc_array(t1_buf, strlen(t1_line_array) + strlen(t1_buf_array) + 1, T1_BUF_SIZE);
         strcat(t1_buf_array, t1_line_array);
+        alloc_array(t1_line, strlen(t1_buf_array) + 1, T1_BUF_SIZE);
         strcpy(t1_line_array, t1_buf_array);
         t1_line_ptr = eol(t1_line_array);
     }