Skip to content

Latest commit

 

History

History
566 lines (454 loc) · 16 KB

wad.c

File metadata and controls

566 lines (454 loc) · 16 KB
 
Dec 15, 2003
Dec 15, 2003
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
/*
* WAD support routines for PhysicsFS.
*
* This driver handles DOOM engine archives ("wads").
* This format (but not this driver) was designed by id Software for use
* with the DOOM engine.
* The specs of the format are from the unofficial doom specs v1.666
* found here: http://www.gamers.org/dhs/helpdocs/dmsp1666.html
* The format of the archive: (from the specs)
*
* A WAD file has three parts:
* (1) a twelve-byte header
* (2) one or more "lumps"
* (3) a directory or "info table" that contains the names, offsets, and
* sizes of all the lumps in the WAD
*
* The header consists of three four-byte parts:
* (a) an ASCII string which must be either "IWAD" or "PWAD"
* (b) a 4-byte (long) integer which is the number of lumps in the wad
* (c) a long integer which is the file offset to the start of
* the directory
*
* The directory has one 16-byte entry for every lump. Each entry consists
* of three parts:
*
* (a) a long integer, the file offset to the start of the lump
* (b) a long integer, the size of the lump in bytes
* (c) an 8-byte ASCII string, the name of the lump, padded with zeros.
* For example, the "DEMO1" entry in hexadecimal would be
* (44 45 4D 4F 31 00 00 00)
*
* Note that there is no way to tell if an opened WAD archive is a
* IWAD or PWAD with this archiver.
* I couldn't think of a way to provide that information, without being too
* hacky.
* I don't think it's really that important though.
*
*
* Please see the file LICENSE in the source's root directory.
*
* This file written by Travis Wells, based on the GRP archiver by
* Ryan C. Gordon.
*/
#if HAVE_CONFIG_H
# include <config.h>
#endif
#if (defined PHYSFS_SUPPORTS_WAD)
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "physfs.h"
#define __PHYSICSFS_INTERNAL__
#include "physfs_internal.h"
typedef struct
{
Dec 18, 2003
Dec 18, 2003
61
char name[18];
Dec 15, 2003
Dec 15, 2003
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
PHYSFS_uint32 startPos;
PHYSFS_uint32 size;
} WADentry;
typedef struct
{
char *filename;
PHYSFS_sint64 last_mod_time;
PHYSFS_uint32 entryCount;
PHYSFS_uint32 entryOffset;
WADentry *entries;
} WADinfo;
typedef struct
{
void *handle;
WADentry *entry;
PHYSFS_uint32 curPos;
} WADfileinfo;
Sep 26, 2004
Sep 26, 2004
83
static PHYSFS_sint64 WAD_read(fvoid *opaque, void *buffer,
Dec 15, 2003
Dec 15, 2003
84
PHYSFS_uint32 objSize, PHYSFS_uint32 objCount);
Sep 26, 2004
Sep 26, 2004
85
static PHYSFS_sint64 WAD_write(fvoid *opaque, const void *buffer,
Dec 15, 2003
Dec 15, 2003
86
PHYSFS_uint32 objSize, PHYSFS_uint32 objCount);
Sep 26, 2004
Sep 26, 2004
87
88
89
90
91
static int WAD_eof(fvoid *opaque);
static PHYSFS_sint64 WAD_tell(fvoid *opaque);
static int WAD_seek(fvoid *opaque, PHYSFS_uint64 offset);
static PHYSFS_sint64 WAD_fileLength(fvoid *opaque);
static int WAD_fileClose(fvoid *opaque);
Dec 15, 2003
Dec 15, 2003
92
static int WAD_isArchive(const char *filename, int forWriting);
Sep 26, 2004
Sep 26, 2004
93
static void *WAD_openArchive(const char *name, int forWriting);
Sep 26, 2004
Sep 26, 2004
94
static LinkedStringList *WAD_enumerateFiles(dvoid *opaque,
Dec 15, 2003
Dec 15, 2003
95
96
const char *dirname,
int omitSymLinks);
Sep 26, 2004
Sep 26, 2004
97
98
99
100
101
102
103
104
105
106
static int WAD_exists(dvoid *opaque, const char *name);
static int WAD_isDirectory(dvoid *opaque, const char *name, int *fileExists);
static int WAD_isSymLink(dvoid *opaque, const char *name, int *fileExists);
static PHYSFS_sint64 WAD_getLastModTime(dvoid *opaque, const char *n, int *e);
static fvoid *WAD_openRead(dvoid *opaque, const char *name, int *exist);
static fvoid *WAD_openWrite(dvoid *opaque, const char *name);
static fvoid *WAD_openAppend(dvoid *opaque, const char *name);
static int WAD_remove(dvoid *opaque, const char *name);
static int WAD_mkdir(dvoid *opaque, const char *name);
static void WAD_dirClose(dvoid *opaque);
Dec 15, 2003
Dec 15, 2003
107
108
109
110
111
112
113
114
115
116
const PHYSFS_ArchiveInfo __PHYSFS_ArchiveInfo_WAD =
{
"WAD",
/* !!! FIXME WAD_ARCHIVE_DESCRIPTION, */ "DOOM engine format",
"Travis Wells <traviswells@mchsi.com>",
"http://www.3dmm2.com/doom/",
};
Sep 26, 2004
Sep 26, 2004
117
const PHYSFS_Archiver __PHYSFS_Archiver_WAD =
Dec 15, 2003
Dec 15, 2003
118
119
120
121
122
123
124
125
126
127
128
129
130
131
{
&__PHYSFS_ArchiveInfo_WAD,
WAD_isArchive, /* isArchive() method */
WAD_openArchive, /* openArchive() method */
WAD_enumerateFiles, /* enumerateFiles() method */
WAD_exists, /* exists() method */
WAD_isDirectory, /* isDirectory() method */
WAD_isSymLink, /* isSymLink() method */
WAD_getLastModTime, /* getLastModTime() method */
WAD_openRead, /* openRead() method */
WAD_openWrite, /* openWrite() method */
WAD_openAppend, /* openAppend() method */
WAD_remove, /* remove() method */
WAD_mkdir, /* mkdir() method */
Sep 26, 2004
Sep 26, 2004
132
133
134
135
136
137
138
139
WAD_dirClose, /* dirClose() method */
WAD_read, /* read() method */
WAD_write, /* write() method */
WAD_eof, /* eof() method */
WAD_tell, /* tell() method */
WAD_seek, /* seek() method */
WAD_fileLength, /* fileLength() method */
WAD_fileClose /* fileClose() method */
Dec 15, 2003
Dec 15, 2003
140
141
142
143
};
Sep 26, 2004
Sep 26, 2004
144
static void WAD_dirClose(dvoid *opaque)
Dec 15, 2003
Dec 15, 2003
145
{
Sep 26, 2004
Sep 26, 2004
146
WADinfo *info = ((WADinfo *) opaque);
Dec 15, 2003
Dec 15, 2003
147
148
149
150
151
152
free(info->filename);
free(info->entries);
free(info);
} /* WAD_dirClose */
Sep 26, 2004
Sep 26, 2004
153
static PHYSFS_sint64 WAD_read(fvoid *opaque, void *buffer,
Dec 15, 2003
Dec 15, 2003
154
155
PHYSFS_uint32 objSize, PHYSFS_uint32 objCount)
{
Sep 26, 2004
Sep 26, 2004
156
WADfileinfo *finfo = (WADfileinfo *) opaque;
Dec 15, 2003
Dec 15, 2003
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
WADentry *entry = finfo->entry;
PHYSFS_uint32 bytesLeft = entry->size - finfo->curPos;
PHYSFS_uint32 objsLeft = (bytesLeft / objSize);
PHYSFS_sint64 rc;
if (objsLeft < objCount)
objCount = objsLeft;
rc = __PHYSFS_platformRead(finfo->handle, buffer, objSize, objCount);
if (rc > 0)
finfo->curPos += (PHYSFS_uint32) (rc * objSize);
return(rc);
} /* WAD_read */
Sep 26, 2004
Sep 26, 2004
173
static PHYSFS_sint64 WAD_write(fvoid *opaque, const void *buffer,
Dec 15, 2003
Dec 15, 2003
174
175
176
177
178
179
PHYSFS_uint32 objSize, PHYSFS_uint32 objCount)
{
BAIL_MACRO(ERR_NOT_SUPPORTED, -1);
} /* WAD_write */
Sep 26, 2004
Sep 26, 2004
180
static int WAD_eof(fvoid *opaque)
Dec 15, 2003
Dec 15, 2003
181
{
Sep 26, 2004
Sep 26, 2004
182
WADfileinfo *finfo = (WADfileinfo *) opaque;
Dec 15, 2003
Dec 15, 2003
183
184
185
186
187
WADentry *entry = finfo->entry;
return(finfo->curPos >= entry->size);
} /* WAD_eof */
Sep 26, 2004
Sep 26, 2004
188
static PHYSFS_sint64 WAD_tell(fvoid *opaque)
Dec 15, 2003
Dec 15, 2003
189
{
Sep 26, 2004
Sep 26, 2004
190
return(((WADfileinfo *) opaque)->curPos);
Dec 15, 2003
Dec 15, 2003
191
192
193
} /* WAD_tell */
Sep 26, 2004
Sep 26, 2004
194
static int WAD_seek(fvoid *opaque, PHYSFS_uint64 offset)
Dec 15, 2003
Dec 15, 2003
195
{
Sep 26, 2004
Sep 26, 2004
196
WADfileinfo *finfo = (WADfileinfo *) opaque;
Dec 15, 2003
Dec 15, 2003
197
198
199
200
201
202
203
204
205
206
207
208
209
WADentry *entry = finfo->entry;
int rc;
BAIL_IF_MACRO(offset < 0, ERR_INVALID_ARGUMENT, 0);
BAIL_IF_MACRO(offset >= entry->size, ERR_PAST_EOF, 0);
rc = __PHYSFS_platformSeek(finfo->handle, entry->startPos + offset);
if (rc)
finfo->curPos = (PHYSFS_uint32) offset;
return(rc);
} /* WAD_seek */
Sep 26, 2004
Sep 26, 2004
210
static PHYSFS_sint64 WAD_fileLength(fvoid *opaque)
Dec 15, 2003
Dec 15, 2003
211
{
Sep 26, 2004
Sep 26, 2004
212
WADfileinfo *finfo = (WADfileinfo *) opaque;
Dec 15, 2003
Dec 15, 2003
213
214
215
216
return((PHYSFS_sint64) finfo->entry->size);
} /* WAD_fileLength */
Sep 26, 2004
Sep 26, 2004
217
static int WAD_fileClose(fvoid *opaque)
Dec 15, 2003
Dec 15, 2003
218
{
Sep 26, 2004
Sep 26, 2004
219
WADfileinfo *finfo = (WADfileinfo *) opaque;
Dec 15, 2003
Dec 15, 2003
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
BAIL_IF_MACRO(!__PHYSFS_platformClose(finfo->handle), NULL, 0);
free(finfo);
return(1);
} /* WAD_fileClose */
static int wad_open(const char *filename, int forWriting,
void **fh, PHYSFS_uint32 *count,PHYSFS_uint32 *offset)
{
PHYSFS_uint8 buf[4];
*fh = NULL;
BAIL_IF_MACRO(forWriting, ERR_ARC_IS_READ_ONLY, 0);
*fh = __PHYSFS_platformOpenRead(filename);
BAIL_IF_MACRO(*fh == NULL, NULL, 0);
if (__PHYSFS_platformRead(*fh, buf, 4, 1) != 1)
goto openWad_failed;
if (memcmp(buf, "IWAD", 4) != 0 && memcmp(buf, "PWAD", 4) != 0)
{
__PHYSFS_setError(ERR_UNSUPPORTED_ARCHIVE);
goto openWad_failed;
} /* if */
if (__PHYSFS_platformRead(*fh, count, sizeof (PHYSFS_uint32), 1) != 1)
goto openWad_failed;
*count = PHYSFS_swapULE32(*count);
if (__PHYSFS_platformRead(*fh, offset, sizeof (PHYSFS_uint32), 1) != 1)
goto openWad_failed;
*offset = PHYSFS_swapULE32(*offset);
return(1);
openWad_failed:
if (*fh != NULL)
__PHYSFS_platformClose(*fh);
*count = -1;
*fh = NULL;
return(0);
} /* wad_open */
static int WAD_isArchive(const char *filename, int forWriting)
{
void *fh;
PHYSFS_uint32 fileCount,offset;
int retval = wad_open(filename, forWriting, &fh, &fileCount,&offset);
if (fh != NULL)
__PHYSFS_platformClose(fh);
return(retval);
} /* WAD_isArchive */
static int wad_entry_cmp(void *_a, PHYSFS_uint32 one, PHYSFS_uint32 two)
{
WADentry *a = (WADentry *) _a;
return(strcmp(a[one].name, a[two].name));
} /* wad_entry_cmp */
static void wad_entry_swap(void *_a, PHYSFS_uint32 one, PHYSFS_uint32 two)
{
WADentry tmp;
WADentry *first = &(((WADentry *) _a)[one]);
WADentry *second = &(((WADentry *) _a)[two]);
memcpy(&tmp, first, sizeof (WADentry));
memcpy(first, second, sizeof (WADentry));
memcpy(second, &tmp, sizeof (WADentry));
} /* wad_entry_swap */
static int wad_load_entries(const char *name, int forWriting, WADinfo *info)
{
void *fh = NULL;
PHYSFS_uint32 fileCount;
PHYSFS_uint32 directoryOffset;
WADentry *entry;
Dec 29, 2003
Dec 29, 2003
305
char lastDirectory[9];
Dec 18, 2003
Dec 18, 2003
306
307
lastDirectory[8] = 0; /* Make sure lastDirectory stays null-terminated. */
Dec 15, 2003
Dec 15, 2003
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
BAIL_IF_MACRO(!wad_open(name, forWriting, &fh, &fileCount,&directoryOffset), NULL, 0);
info->entryCount = fileCount;
info->entries = (WADentry *) malloc(sizeof (WADentry) * fileCount);
if (info->entries == NULL)
{
__PHYSFS_platformClose(fh);
BAIL_MACRO(ERR_OUT_OF_MEMORY, 0);
} /* if */
__PHYSFS_platformSeek(fh,directoryOffset);
for (entry = info->entries; fileCount > 0; fileCount--, entry++)
{
if (__PHYSFS_platformRead(fh, &entry->startPos, 4, 1) != 1)
{
__PHYSFS_platformClose(fh);
return(0);
} /* if */
if (__PHYSFS_platformRead(fh, &entry->size, 4, 1) != 1)
{
__PHYSFS_platformClose(fh);
return(0);
} /* if */
if (__PHYSFS_platformRead(fh, &entry->name, 8, 1) != 1)
{
__PHYSFS_platformClose(fh);
return(0);
} /* if */
entry->name[8] = '\0'; /* name might not be null-terminated in file. */
entry->size = PHYSFS_swapULE32(entry->size);
entry->startPos = PHYSFS_swapULE32(entry->startPos);
} /* for */
__PHYSFS_platformClose(fh);
__PHYSFS_sort(info->entries, info->entryCount,
wad_entry_cmp, wad_entry_swap);
return(1);
} /* wad_load_entries */
Sep 26, 2004
Sep 26, 2004
353
static void *WAD_openArchive(const char *name, int forWriting)
Dec 15, 2003
Dec 15, 2003
354
355
{
PHYSFS_sint64 modtime = __PHYSFS_platformGetLastModTime(name);
Sep 26, 2004
Sep 26, 2004
356
WADinfo *info = malloc(sizeof (WADinfo));
Dec 15, 2003
Dec 15, 2003
357
Sep 26, 2004
Sep 26, 2004
358
BAIL_IF_MACRO(info == NULL, ERR_OUT_OF_MEMORY, NULL);
Dec 15, 2003
Dec 15, 2003
359
360
361
362
363
364
365
366
367
368
369
370
371
372
memset(info, '\0', sizeof (WADinfo));
info->filename = (char *) malloc(strlen(name) + 1);
if (info->filename == NULL)
{
__PHYSFS_setError(ERR_OUT_OF_MEMORY);
goto WAD_openArchive_failed;
} /* if */
if (!wad_load_entries(name, forWriting, info))
goto WAD_openArchive_failed;
strcpy(info->filename, name);
info->last_mod_time = modtime;
Sep 26, 2004
Sep 26, 2004
373
return(info);
Dec 15, 2003
Dec 15, 2003
374
375
WAD_openArchive_failed:
Sep 26, 2004
Sep 26, 2004
376
if (info != NULL)
Dec 15, 2003
Dec 15, 2003
377
{
Sep 26, 2004
Sep 26, 2004
378
379
380
381
382
if (info->filename != NULL)
free(info->filename);
if (info->entries != NULL)
free(info->entries);
free(info);
Dec 15, 2003
Dec 15, 2003
383
384
385
386
387
388
} /* if */
return(NULL);
} /* WAD_openArchive */
Sep 26, 2004
Sep 26, 2004
389
static LinkedStringList *WAD_enumerateFiles(dvoid *opaque,
Dec 15, 2003
Dec 15, 2003
390
391
392
const char *dirname,
int omitSymLinks)
{
Sep 26, 2004
Sep 26, 2004
393
WADinfo *info = ((WADinfo *) opaque);
Dec 15, 2003
Dec 15, 2003
394
395
396
397
WADentry *entry = info->entries;
LinkedStringList *retval = NULL, *p = NULL;
PHYSFS_uint32 max = info->entryCount;
PHYSFS_uint32 i;
Dec 18, 2003
Dec 18, 2003
398
char *sep;
Dec 15, 2003
Dec 15, 2003
399
Dec 18, 2003
Dec 18, 2003
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
if (dirname[0] == 0)
{
for (i = 0; i < max; i++, entry++)
{
if (strchr(entry->name, '/') == NULL)
{
retval = __PHYSFS_addToLinkedStringList(retval, &p,
entry->name, -1);
} /* if */
} /* for */
} /* if */
else
{
for (i = 0; i < max; i++, entry++)
{
sep = strchr(entry->name, '/');
if (sep != NULL)
{
if (strncmp(dirname, entry->name, (sep-entry->name)) == 0)
{
retval = __PHYSFS_addToLinkedStringList(retval, &p,
sep + 1, -1);
} /* if */
} /* if */
} /* for */
} /* else */
Dec 15, 2003
Dec 15, 2003
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
return(retval);
} /* WAD_enumerateFiles */
static WADentry *wad_find_entry(WADinfo *info, const char *name)
{
WADentry *a = info->entries;
PHYSFS_sint32 lo = 0;
PHYSFS_sint32 hi = (PHYSFS_sint32) (info->entryCount - 1);
PHYSFS_sint32 middle;
int rc;
while (lo <= hi)
{
middle = lo + ((hi - lo) / 2);
rc = strcmp(name, a[middle].name);
if (rc == 0) /* found it! */
return(&a[middle]);
else if (rc > 0)
lo = middle + 1;
else
hi = middle - 1;
} /* while */
BAIL_MACRO(ERR_NO_SUCH_FILE, NULL);
} /* wad_find_entry */
Sep 26, 2004
Sep 26, 2004
455
static int WAD_exists(dvoid *opaque, const char *name)
Dec 15, 2003
Dec 15, 2003
456
{
Sep 26, 2004
Sep 26, 2004
457
return(wad_find_entry(((WADinfo *) opaque), name) != NULL);
Dec 15, 2003
Dec 15, 2003
458
459
460
} /* WAD_exists */
Sep 26, 2004
Sep 26, 2004
461
static int WAD_isDirectory(dvoid *opaque, const char *name, int *fileExists)
Dec 15, 2003
Dec 15, 2003
462
{
Sep 26, 2004
Sep 26, 2004
463
WADentry *entry = wad_find_entry(((WADinfo *) opaque), name);
Dec 18, 2003
Dec 18, 2003
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
if (entry != NULL)
{
char *n;
*fileExists = 1;
/* Can't be a directory if it's a subdirectory. */
if (strchr(entry->name, '/') != NULL)
return(0);
/* Check if it matches "MAP??" or "E?M?" ... */
n = entry->name;
if ((n[0] == 'E' && n[2] == 'M') ||
(n[0] == 'M' && n[1] == 'A' && n[2] == 'P' && n[6] == 0))
{
return(1);
} /* if */
return(0);
} /* if */
else
{
*fileExists = 0;
return(0);
} /* else */
Dec 15, 2003
Dec 15, 2003
488
489
490
} /* WAD_isDirectory */
Sep 26, 2004
Sep 26, 2004
491
static int WAD_isSymLink(dvoid *opaque, const char *name, int *fileExists)
Dec 15, 2003
Dec 15, 2003
492
{
Sep 26, 2004
Sep 26, 2004
493
*fileExists = WAD_exists(opaque, name);
Dec 15, 2003
Dec 15, 2003
494
495
496
497
return(0); /* never symlinks in a wad. */
} /* WAD_isSymLink */
Sep 26, 2004
Sep 26, 2004
498
static PHYSFS_sint64 WAD_getLastModTime(dvoid *opaque,
Dec 15, 2003
Dec 15, 2003
499
500
501
const char *name,
int *fileExists)
{
Sep 26, 2004
Sep 26, 2004
502
WADinfo *info = ((WADinfo *) opaque);
Dec 15, 2003
Dec 15, 2003
503
504
505
506
PHYSFS_sint64 retval = -1;
*fileExists = (wad_find_entry(info, name) != NULL);
if (*fileExists) /* use time of WAD itself in the physical filesystem. */
Sep 26, 2004
Sep 26, 2004
507
retval = info->last_mod_time;
Dec 15, 2003
Dec 15, 2003
508
509
510
511
512
return(retval);
} /* WAD_getLastModTime */
Sep 26, 2004
Sep 26, 2004
513
static fvoid *WAD_openRead(dvoid *opaque, const char *fnm, int *fileExists)
Dec 15, 2003
Dec 15, 2003
514
{
Sep 26, 2004
Sep 26, 2004
515
WADinfo *info = ((WADinfo *) opaque);
Dec 15, 2003
Dec 15, 2003
516
517
518
519
520
521
522
523
WADfileinfo *finfo;
WADentry *entry;
entry = wad_find_entry(info, fnm);
*fileExists = (entry != NULL);
BAIL_IF_MACRO(entry == NULL, NULL, NULL);
finfo = (WADfileinfo *) malloc(sizeof (WADfileinfo));
Sep 26, 2004
Sep 26, 2004
524
BAIL_IF_MACRO(finfo == NULL, ERR_OUT_OF_MEMORY, NULL);
Dec 15, 2003
Dec 15, 2003
525
526
527
528
529
530
531
532
533
534
535
finfo->handle = __PHYSFS_platformOpenRead(info->filename);
if ( (finfo->handle == NULL) ||
(!__PHYSFS_platformSeek(finfo->handle, entry->startPos)) )
{
free(finfo);
return(NULL);
} /* if */
finfo->curPos = 0;
finfo->entry = entry;
Sep 26, 2004
Sep 26, 2004
536
return(finfo);
Dec 15, 2003
Dec 15, 2003
537
538
539
} /* WAD_openRead */
Sep 26, 2004
Sep 26, 2004
540
static fvoid *WAD_openWrite(dvoid *opaque, const char *name)
Dec 15, 2003
Dec 15, 2003
541
542
543
544
545
{
BAIL_MACRO(ERR_NOT_SUPPORTED, NULL);
} /* WAD_openWrite */
Sep 26, 2004
Sep 26, 2004
546
static fvoid *WAD_openAppend(dvoid *opaque, const char *name)
Dec 15, 2003
Dec 15, 2003
547
548
549
550
551
{
BAIL_MACRO(ERR_NOT_SUPPORTED, NULL);
} /* WAD_openAppend */
Sep 26, 2004
Sep 26, 2004
552
static int WAD_remove(dvoid *opaque, const char *name)
Dec 15, 2003
Dec 15, 2003
553
554
555
556
557
{
BAIL_MACRO(ERR_NOT_SUPPORTED, 0);
} /* WAD_remove */
Sep 26, 2004
Sep 26, 2004
558
static int WAD_mkdir(dvoid *opaque, const char *name)
Dec 15, 2003
Dec 15, 2003
559
560
561
562
563
564
565
{
BAIL_MACRO(ERR_NOT_SUPPORTED, 0);
} /* WAD_mkdir */
#endif /* defined PHYSFS_SUPPORTS_WAD */
/* end of wad.c ... */