aboutsummaryrefslogtreecommitdiff
path: root/libXfont/src/builtins/dir.c
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2009-07-25 14:29:10 +0000
committermarha <marha@users.sourceforge.net>2009-07-25 14:29:10 +0000
commitddfb922180a6a847d52609592a2bdb37179ca439 (patch)
tree7cc662bfb9ffb45c4c4452ea373e3c1a843b395a /libXfont/src/builtins/dir.c
parent02934f83dd4f5848083e2e5cdbc6ef7f60361f06 (diff)
parent2fb179f86b0f9ecb7876759b87f9c64634a3f114 (diff)
downloadvcxsrv-ddfb922180a6a847d52609592a2bdb37179ca439.tar.gz
vcxsrv-ddfb922180a6a847d52609592a2bdb37179ca439.tar.bz2
vcxsrv-ddfb922180a6a847d52609592a2bdb37179ca439.zip
svn merge file:///D:/svnrepos/vcxsrv/branches/released .
Gives currently link errors. xorg-server needs to be upgraded to.
Diffstat (limited to 'libXfont/src/builtins/dir.c')
-rw-r--r--libXfont/src/builtins/dir.c19
1 files changed, 5 insertions, 14 deletions
diff --git a/libXfont/src/builtins/dir.c b/libXfont/src/builtins/dir.c
index dd2ea1a86..bf351b147 100644
--- a/libXfont/src/builtins/dir.c
+++ b/libXfont/src/builtins/dir.c
@@ -1,6 +1,4 @@
/*
- * Id: dir.c,v 1.2 1999/11/02 06:16:47 keithp Exp $
- *
* Copyright 1999 SuSE, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software and its
@@ -22,7 +20,6 @@
*
* Author: Keith Packard, SuSE, Inc.
*/
-/* $XFree86: xc/lib/font/builtins/dir.c,v 1.3 1999/12/30 02:29:49 robin Exp $ */
#ifdef HAVE_CONFIG_H
#include <config.h>
@@ -39,17 +36,13 @@ BuiltinDirsDup (const BuiltinDirPtr a_dirs,
if (!a_dirs)
return NULL ;
- dirs = xcalloc (a_dirs_len, sizeof (BuiltinDirRec)) ;
+ dirs = calloc (a_dirs_len, sizeof (BuiltinDirRec)) ;
if (!dirs)
return NULL ;
for (i=0; i < a_dirs_len; i++) {
- int len = strlen (a_dirs[i].file_name) ;
- dirs[i].file_name = xcalloc (1, len+1) ;
- memmove (dirs[i].file_name, a_dirs[i].file_name, len);
- len = strlen (a_dirs[i].font_name) ;
- dirs[i].font_name = xcalloc (1, len+1) ;
- memmove (dirs[i].font_name, a_dirs[i].font_name, len);
+ dirs[i].file_name = strdup(a_dirs[i].file_name);
+ dirs[i].font_name = strdup(a_dirs[i].font_name);
}
return dirs ;
}
@@ -104,14 +97,12 @@ BuiltinAliasesDup (const BuiltinAliasPtr a_aliases,
if (!a_aliases)
return NULL ;
- aliases = xcalloc (a_aliases_len, sizeof (BuiltinAliasRec)) ;
+ aliases = calloc (a_aliases_len, sizeof (BuiltinAliasRec)) ;
if (!aliases)
return NULL ;
for (i=0; i < a_aliases_len; i++) {
- int len = strlen (a_aliases[i].font_name) ;
- aliases[i].font_name = xcalloc (1, len+1) ;
- memmove (aliases[i].font_name, a_aliases[i].font_name, len);
+ aliases[i].font_name = strdup(a_aliases[i].font_name);
}
return aliases ;
}