aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/xfree86/parser/Files.c
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/hw/xfree86/parser/Files.c')
-rw-r--r--xorg-server/hw/xfree86/parser/Files.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/xorg-server/hw/xfree86/parser/Files.c b/xorg-server/hw/xfree86/parser/Files.c
index 0d3e47ac5..a6e18dd2c 100644
--- a/xorg-server/hw/xfree86/parser/Files.c
+++ b/xorg-server/hw/xfree86/parser/Files.c
@@ -97,8 +97,7 @@ xf86parseFilesSection(void)
j = FALSE;
str = val.str;
if (ptr->file_fontpath == NULL) {
- ptr->file_fontpath = malloc(1);
- ptr->file_fontpath[0] = '\0';
+ ptr->file_fontpath = calloc(1, 1);
i = strlen(str) + 1;
}
else {