Fixed more Visual Studio compiler warnings.
This commit is contained in:
parent
1bacc6d6af
commit
53225ca62c
|
@ -358,7 +358,7 @@ static int iso_readimage(ISO9660Handle *handle, PHYSFS_uint64 where,
|
||||||
handle->currpos += (PHYSFS_uint64) rc;
|
handle->currpos += (PHYSFS_uint64) rc;
|
||||||
|
|
||||||
__PHYSFS_platformReleaseMutex(handle->mutex);
|
__PHYSFS_platformReleaseMutex(handle->mutex);
|
||||||
return rc;
|
return (int) rc; /* !!! FIXME: should this return "int" ? */
|
||||||
} /* iso_readimage */
|
} /* iso_readimage */
|
||||||
|
|
||||||
|
|
||||||
|
@ -709,7 +709,7 @@ static int iso_file_seek_foreign(ISO9660FileHandle *fhandle,
|
||||||
PHYSFS_sint64 pos;
|
PHYSFS_sint64 pos;
|
||||||
|
|
||||||
BAIL_IF(offset < 0, PHYSFS_ERR_INVALID_ARGUMENT, 0);
|
BAIL_IF(offset < 0, PHYSFS_ERR_INVALID_ARGUMENT, 0);
|
||||||
BAIL_IF(((PHYSFS_uint64) offset) >= fhandle->filesize, PHYSFS_ERR_PAST_EOF, 0);
|
BAIL_IF(offset >= fhandle->filesize, PHYSFS_ERR_PAST_EOF, 0);
|
||||||
|
|
||||||
pos = fhandle->startblock * 2048 + offset;
|
pos = fhandle->startblock * 2048 + offset;
|
||||||
BAIL_IF_ERRPASS(!fhandle->io->seek(fhandle->io, pos), -1);
|
BAIL_IF_ERRPASS(!fhandle->io->seek(fhandle->io, pos), -1);
|
||||||
|
|
|
@ -1681,7 +1681,7 @@ static PHYSFS_Io *ZIP_openRead(void *opaque, const char *filename)
|
||||||
const PHYSFS_uint64 len = (PHYSFS_uint64) (ptr - filename);
|
const PHYSFS_uint64 len = (PHYSFS_uint64) (ptr - filename);
|
||||||
char *str = (char *) __PHYSFS_smallAlloc(len + 1);
|
char *str = (char *) __PHYSFS_smallAlloc(len + 1);
|
||||||
BAIL_IF(!str, PHYSFS_ERR_OUT_OF_MEMORY, NULL);
|
BAIL_IF(!str, PHYSFS_ERR_OUT_OF_MEMORY, NULL);
|
||||||
memcpy(str, filename, len);
|
memcpy(str, filename, (size_t) len);
|
||||||
str[len] = '\0';
|
str[len] = '\0';
|
||||||
entry = zip_find_entry(info, str);
|
entry = zip_find_entry(info, str);
|
||||||
__PHYSFS_smallFree(str);
|
__PHYSFS_smallFree(str);
|
||||||
|
|
Loading…
Reference in New Issue