21 lines
720 B
Diff
21 lines
720 B
Diff
commit 1ab07ce0eec4f6c7ed66c7aba3edf8c4315dd907
|
|
Author: Alan Coopersmith <alan.coopersmith@sun.com>
|
|
Date: Tue May 13 17:26:57 2008 -0700
|
|
|
|
FontFileDirectoryChanged: check length of "fonts.alias" as well as "fonts.dir"
|
|
|
|
diff --git a/src/fontfile/dirfile.c b/src/fontfile/dirfile.c
|
|
index a13798a..1489938 100755
|
|
--- a/src/fontfile/dirfile.c
|
|
+++ b/src/fontfile/dirfile.c
|
|
@@ -176,6 +176,9 @@ FontFileDirectoryChanged(FontDirectoryPtr dir)
|
|
}
|
|
if (dir->dir_mtime != statb.st_mtime)
|
|
return TRUE;
|
|
+
|
|
+ if ((strlen(dir->directory) + sizeof(FontAliasFile)) > sizeof(dir_file))
|
|
+ return FALSE;
|
|
strcpy (dir_file, dir->directory);
|
|
strcat (dir_file, FontAliasFile);
|
|
if (stat (dir_file, &statb) == -1)
|