]> granicus.if.org Git - graphviz/commitdiff
remove use of stack buffer in utf8ToLatin1
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 3 Oct 2020 19:18:32 +0000 (12:18 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 10 Oct 2020 17:46:07 +0000 (10:46 -0700)
For similar reasons to the prior commits.

lib/common/utils.c

index 1a5df5bfb53938e22da75ac8dc3955be3bc8951e..826e69976ab1b5262ee7b9a1574d6cd100c5669c 100644 (file)
@@ -1597,11 +1597,10 @@ utf8ToLatin1 (char* s)
 {
     char*  ns;
     agxbuf xb;
-    unsigned char buf[BUFSIZ];
     unsigned char c;
     unsigned char outc;
 
-    agxbinit(&xb, BUFSIZ, buf);
+    agxbinit(&xb, 0, NULL);
 
     while ((c = *(unsigned char*)s++)) {
        if (c < 0x7F)