Fixed details of PHYSFS_Archiver's stat method.
This commit is contained in:
parent
024784efbd
commit
f99f0ef9e7
|
@ -237,7 +237,7 @@ static void DIR_dirClose(dvoid *opaque)
|
||||||
} /* DIR_dirClose */
|
} /* DIR_dirClose */
|
||||||
|
|
||||||
|
|
||||||
static int DIR_stat(fvoid *opaque, const char *name, int *exists,
|
static int DIR_stat(dvoid *opaque, const char *name, int *exists,
|
||||||
PHYSFS_Stat *stat)
|
PHYSFS_Stat *stat)
|
||||||
{
|
{
|
||||||
char *d = __PHYSFS_platformCvtToDependent((char *) opaque, name, NULL);
|
char *d = __PHYSFS_platformCvtToDependent((char *) opaque, name, NULL);
|
||||||
|
|
|
@ -433,7 +433,7 @@ static int GRP_mkdir(dvoid *opaque, const char *name)
|
||||||
} /* GRP_mkdir */
|
} /* GRP_mkdir */
|
||||||
|
|
||||||
|
|
||||||
static int GRP_stat(fvoid *opaque, const char *filename, int *exists,
|
static int GRP_stat(dvoid *opaque, const char *filename, int *exists,
|
||||||
PHYSFS_Stat *stat)
|
PHYSFS_Stat *stat)
|
||||||
{
|
{
|
||||||
const GRPinfo *info = (const GRPinfo *) opaque;
|
const GRPinfo *info = (const GRPinfo *) opaque;
|
||||||
|
|
|
@ -468,7 +468,7 @@ static int HOG_mkdir(dvoid *opaque, const char *name)
|
||||||
} /* HOG_mkdir */
|
} /* HOG_mkdir */
|
||||||
|
|
||||||
|
|
||||||
static int HOG_stat(fvoid *opaque, const char *filename, int *exists,
|
static int HOG_stat(dvoid *opaque, const char *filename, int *exists,
|
||||||
PHYSFS_Stat *stat)
|
PHYSFS_Stat *stat)
|
||||||
{
|
{
|
||||||
const HOGinfo *info = (const HOGinfo *) opaque;
|
const HOGinfo *info = (const HOGinfo *) opaque;
|
||||||
|
|
|
@ -688,7 +688,7 @@ static int LZMA_mkdir(dvoid *opaque, const char *name)
|
||||||
BAIL_MACRO(ERR_NOT_SUPPORTED, 0);
|
BAIL_MACRO(ERR_NOT_SUPPORTED, 0);
|
||||||
} /* LZMA_mkdir */
|
} /* LZMA_mkdir */
|
||||||
|
|
||||||
static int LZMA_stat(fvoid *opaque, const char *filename, int *exists,
|
static int LZMA_stat(dvoid *opaque, const char *filename, int *exists,
|
||||||
PHYSFS_Stat *stat)
|
PHYSFS_Stat *stat)
|
||||||
{
|
{
|
||||||
const LZMAarchive *archive = (const LZMAarchive *) opaque;
|
const LZMAarchive *archive = (const LZMAarchive *) opaque;
|
||||||
|
|
|
@ -428,7 +428,7 @@ static int MVL_mkdir(dvoid *opaque, const char *name)
|
||||||
} /* MVL_mkdir */
|
} /* MVL_mkdir */
|
||||||
|
|
||||||
|
|
||||||
static int MVL_stat(fvoid *opaque, const char *filename, int *exists,
|
static int MVL_stat(dvoid *opaque, const char *filename, int *exists,
|
||||||
PHYSFS_Stat *stat)
|
PHYSFS_Stat *stat)
|
||||||
{
|
{
|
||||||
const MVLinfo *info = (const MVLinfo *) opaque;
|
const MVLinfo *info = (const MVLinfo *) opaque;
|
||||||
|
|
|
@ -581,7 +581,7 @@ static int QPAK_mkdir(dvoid *opaque, const char *name)
|
||||||
} /* QPAK_mkdir */
|
} /* QPAK_mkdir */
|
||||||
|
|
||||||
|
|
||||||
static int QPAK_stat(fvoid *opaque, const char *filename, int *exists,
|
static int QPAK_stat(dvoid *opaque, const char *filename, int *exists,
|
||||||
PHYSFS_Stat *stat)
|
PHYSFS_Stat *stat)
|
||||||
{
|
{
|
||||||
int isDir = 0;
|
int isDir = 0;
|
||||||
|
|
|
@ -487,7 +487,7 @@ static int WAD_mkdir(dvoid *opaque, const char *name)
|
||||||
} /* WAD_mkdir */
|
} /* WAD_mkdir */
|
||||||
|
|
||||||
|
|
||||||
static int WAD_stat(fvoid *opaque, const char *filename, int *exists,
|
static int WAD_stat(dvoid *opaque, const char *filename, int *exists,
|
||||||
PHYSFS_Stat *stat)
|
PHYSFS_Stat *stat)
|
||||||
{
|
{
|
||||||
const WADinfo *info = (const WADinfo *) opaque;
|
const WADinfo *info = (const WADinfo *) opaque;
|
||||||
|
|
|
@ -1399,7 +1399,7 @@ static int ZIP_mkdir(dvoid *opaque, const char *name)
|
||||||
} /* ZIP_mkdir */
|
} /* ZIP_mkdir */
|
||||||
|
|
||||||
|
|
||||||
static int ZIP_stat(fvoid *opaque, const char *filename, int *exists,
|
static int ZIP_stat(dvoid *opaque, const char *filename, int *exists,
|
||||||
PHYSFS_Stat *stat)
|
PHYSFS_Stat *stat)
|
||||||
{
|
{
|
||||||
int isDir = 0;
|
int isDir = 0;
|
||||||
|
|
|
@ -890,6 +890,12 @@ typedef struct
|
||||||
*/
|
*/
|
||||||
void (*dirClose)(dvoid *opaque);
|
void (*dirClose)(dvoid *opaque);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Obtain basic file metadata.
|
||||||
|
* Returns non-zero on success, zero on failure.
|
||||||
|
* On failure, call __PHYSFS_setError().
|
||||||
|
*/
|
||||||
|
int (*stat)(dvoid *opaque, const char *fn, int *exists, PHYSFS_Stat *stat);
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -944,13 +950,6 @@ typedef struct
|
||||||
* file. On failure, call __PHYSFS_setError().
|
* file. On failure, call __PHYSFS_setError().
|
||||||
*/
|
*/
|
||||||
int (*fileClose)(fvoid *opaque);
|
int (*fileClose)(fvoid *opaque);
|
||||||
|
|
||||||
/* !!! FIXME: return info (may be|is) wrong.
|
|
||||||
* Obtain basic file metadata.
|
|
||||||
* Returns non-zero on success, zero if can't close
|
|
||||||
* file. On failure, call __PHYSFS_setError().
|
|
||||||
*/
|
|
||||||
int (*stat)(fvoid *opaque, const char *fn, int *exists, PHYSFS_Stat *stat);
|
|
||||||
} PHYSFS_Archiver;
|
} PHYSFS_Archiver;
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue