src/gfxinit.c
branchcustombridgeheads
changeset 5645 72ebd9e4cd64
parent 5643 3778051e8095
child 5648 1608018c5ff2
--- a/src/gfxinit.c	Wed Jan 03 08:55:13 2007 +0000
+++ b/src/gfxinit.c	Wed Jan 03 08:56:09 2007 +0000
@@ -121,6 +121,20 @@
 	}
 #endif
 
+#if defined SECOND_DATA_DIR
+	/* If we failed to find the file in the first data directory, we will try the other one */
+
+	if (f == NULL) {
+		snprintf(buf, lengthof(buf), "%s%s", _paths.second_data_dir, file.filename);
+		f = fopen(buf, "rb");
+
+		if (f == NULL) {
+			strtolower(buf + strlen(_paths.second_data_dir) - 1);
+			f = fopen(buf, "rb");
+		}
+	}
+#endif
+
 	if (f != NULL) {
 		md5_state_t filemd5state;
 		md5_byte_t buffer[1024];