aboutsummaryrefslogtreecommitdiff
path: root/fontconfig
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2013-10-24 08:10:01 +0200
committermarha <marha@users.sourceforge.net>2013-10-24 08:10:01 +0200
commit4eb0b643ad978d94837e2d587a5d4358f974a25c (patch)
treeecb04ee3cf0d7c2fa80707218382d68e7a49f621 /fontconfig
parent6d895f30ab93d71afddc612d8b007f2de7f04165 (diff)
downloadvcxsrv-4eb0b643ad978d94837e2d587a5d4358f974a25c.tar.gz
vcxsrv-4eb0b643ad978d94837e2d587a5d4358f974a25c.tar.bz2
vcxsrv-4eb0b643ad978d94837e2d587a5d4358f974a25c.zip
fontconfig mesa xserver git update 24 oct 2013
xserver commit 7ecfab47eb221dbb996ea6c033348b8eceaeb893 fontconfig commit 76ea9af816a50c6bb0b3dc2960460a90fadd9cdb mesa commit a6e45b6a17462f4d261a2d176791469847356923
Diffstat (limited to 'fontconfig')
-rw-r--r--fontconfig/test/test-migration.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/fontconfig/test/test-migration.c b/fontconfig/test/test-migration.c
index a0ab83902..970965186 100644
--- a/fontconfig/test/test-migration.c
+++ b/fontconfig/test/test-migration.c
@@ -4,6 +4,11 @@
#include <unistd.h>
#include <sys/types.h>
#include <dirent.h>
+#ifndef HAVE_STRUCT_DIRENT_D_TYPE
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <unistd.h>
+#endif
#include <fontconfig/fontconfig.h>
FcBool
@@ -36,6 +41,9 @@ unlink_dirs(const char *dir)
size_t len = strlen (dir);
char *n = NULL;
FcBool ret = FcTrue;
+#ifndef HAVE_STRUCT_DIRENT_D_TYPE
+ struct stat statb;
+#endif
if (!d)
return FcFalse;
@@ -53,7 +61,17 @@ unlink_dirs(const char *dir)
strcpy (n, dir);
n[len] = '/';
strcpy (&n[len + 1], e->d_name);
+#ifdef HAVE_STRUCT_DIRENT_D_TYPE
if (e->d_type == DT_DIR)
+#else
+ if (stat (n, &statb) == -1)
+ {
+ fprintf (stderr, "E: %s\n", n);
+ ret = FcFalse;
+ break;
+ }
+ if (S_ISDIR (statb.st_mode))
+#endif
{
if (!unlink_dirs (n))
{