(PS3) Cut down on warnings

This commit is contained in:
twinaphex 2016-04-13 01:49:38 +02:00
parent 928f4e9e65
commit 06ccd36b2f
3 changed files with 8 additions and 4 deletions

View file

@ -76,7 +76,7 @@ int intfstream_seek(intfstream_internal_t *intf,
void intfstream_rewind(intfstream_internal_t *intf);
size_t intfstream_tell(intfstream_internal_t *intf);
int intfstream_tell(intfstream_internal_t *intf);
void intfstream_putc(intfstream_internal_t *intf, int c);

View file

@ -240,6 +240,9 @@ error:
ssize_t filestream_seek(RFILE *stream, ssize_t offset, int whence)
{
#if defined(__CELLOS_LV2__)
uint64_t pos = 0;
#endif
if (!stream)
goto error;
@ -247,7 +250,6 @@ ssize_t filestream_seek(RFILE *stream, ssize_t offset, int whence)
if (sceIoLseek(stream->fd, (SceOff)offset, whence) == -1)
goto error;
#elif defined(__CELLOS_LV2__)
uint64_t pos = 0;
if (cellFsLseek(stream->fd, offset, whence, &pos) != CELL_FS_SUCCEEDED)
goto error;
#else
@ -305,13 +307,15 @@ error:
ssize_t filestream_tell(RFILE *stream)
{
#if defined(__CELLOS_LV2__)
uint64_t pos = 0;
#endif
if (!stream)
goto error;
#if defined(VITA) || defined(PSP)
if (sceIoLseek(stream->fd, 0, SEEK_CUR) < 0)
goto error;
#elif defined(__CELLOS_LV2__)
uint64_t pos = 0;
if (cellFsLseek(stream->fd, 0, CELL_FS_SEEK_CUR, &pos) != CELL_FS_SUCCEEDED)
goto error;
#else

View file

@ -224,7 +224,7 @@ int intfstream_getc(intfstream_internal_t *intf)
return 0;
}
size_t intfstream_tell(intfstream_internal_t *intf)
int intfstream_tell(intfstream_internal_t *intf)
{
if (!intf)
return -1;