openbsd-ports/multimedia/swftools/patches/patch-src_swfstrings_c
sthen c3d32f8946 Zero newly malloc'd address space, avoiding dereferencing a garbage pointer.
Found/patched by me, this version of the patch from upstream via Brad.
2011-10-26 20:17:42 +00:00

13 lines
445 B
Plaintext

$OpenBSD: patch-src_swfstrings_c,v 1.1 2011/10/26 20:17:42 sthen Exp $
--- src/swfstrings.c.orig Wed Oct 26 11:07:47 2011
+++ src/swfstrings.c Wed Oct 26 10:59:47 2011
@@ -208,7 +208,7 @@ int main (int argc,char ** argv)
if(!h) h = (swf.movieSize.ymax - swf.movieSize.ymin) / 20;
}
- id2tag = malloc(sizeof(TAG)*65536);
+ id2tag = rfx_calloc(sizeof(TAG)*65536);
fontnum = 0;
swf_FontEnumerate(&swf,&fontcallback1, 0);