This patch fixes a potential crash in fc-lang if parsed file syntax is incorrect (Coverity defect #763). -- Frederic Crozat <fcrozat@xxxxxxxxxxxx> Mandriva
Index: ChangeLog =================================================================== RCS file: /cvs/fontconfig/fontconfig/ChangeLog,v retrieving revision 1.109.2.192 diff -u -p -r1.109.2.192 ChangeLog --- ChangeLog 11 Apr 2006 05:08:26 -0000 1.109.2.192 +++ ChangeLog 11 Apr 2006 12:15:12 -0000 @@ -1,3 +1,9 @@ +2006-04-11 Frederic Crozat <fcrozat@xxxxxxxxxxxx> + + * fc-lang/fc-lang.c: (scan): + prevent crash when invalid include line is parsed (Coverity defect + #763). + 2006-04-11 Behdad Esfahbod <behdad@xxxxxxxxxxxxxx> reviewed by: plam Index: fc-lang/fc-lang.c =================================================================== RCS file: /cvs/fontconfig/fontconfig/fc-lang/fc-lang.c,v retrieving revision 1.11.4.15 diff -u -p -r1.11.4.15 fc-lang.c --- fc-lang/fc-lang.c 10 Apr 2006 22:08:35 -0000 1.11.4.15 +++ fc-lang/fc-lang.c 11 Apr 2006 12:15:12 -0000 @@ -143,6 +143,9 @@ if (!strncmp (line, "include", 7)) { file = strchr (line, ' '); + if (!file) + fatal (line, lineno, + "invalid syntax, expected: include filename"); while (isspace(*file)) file++; f = scanopen (file);
_______________________________________________ Fontconfig mailing list Fontconfig@xxxxxxxxxxxxxxxxxxxxx http://lists.freedesktop.org/mailman/listinfo/fontconfig