Package: fontconfig Version: 2.8.0-2.1 Severity: normal Tags: patch While debugging fbi using valgrind memory leaks were detected in fcpat.c patch decreases a leak
--- fontconfig-2.8.0/src/fcmatch.c 2009-11-16 22:46:18.000000000 +0000 +++ src/fontconfig-2.8.0/src/fcmatch.c 2012-01-15 18:03:11.000000000 +0000 @@ -552,6 +552,7 @@ if (best) return FcFontRenderPrepare (config, p, best); else + FcPatternDestroy(best); return NULL; } --- fontconfig-2.8.0/src/fcpat.c 2009-11-16 22:46:18.000000000 +0000 +++ src/fontconfig-2.8.0/src/fcpat.c 2012-01-15 20:27:07.000000000 +0000 @@ -361,6 +361,8 @@ e = malloc(s * sizeof (FcPatternElt)); if (e) memcpy(e, e0, p->num * sizeof (FcPatternElt)); + else if (!e) + return FcFalse; } } else @@ -519,14 +521,15 @@ new->next = e->values; e->values = new; } - + return FcTrue; bail2: + FcPatternDestroy(p); FcValueDestroy (value); bail1: FcMemFree (FC_MEM_VALLIST, sizeof (FcValueList)); - free (new); + FcValueListDestroy(new); bail0: return FcFalse; } -- System Information: Debian Release: 6.0.3 APT prefers stable APT policy: (500, 'stable') Architecture: i386 (i686) Kernel: Linux 2.6.32-5-686 (SMP w/1 CPU core) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages fontconfig depends on: ii fontconfig-config 2.8.0-2.1 generic font configuration library ii libc6 2.11.2-10 Embedded GNU C Library: Shared lib ii libexpat1 2.0.1-7 XML parsing C library - runtime li ii libfontconfig1 2.8.0-2.1 generic font configuration library ii libfreetype6 2.4.2-2.1+squeeze3 FreeType 2 font engine, shared lib ii zlib1g 1:1.2.3.4.dfsg-3 compression library - runtime fontconfig recommends no packages. Versions of packages fontconfig suggests: ii defoma 0.11.11 Debian Font Manager -- automatic f -- no debconf information -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org