diff options
author | notaz | 2011-06-07 12:40:49 +0300 |
---|---|---|
committer | notaz | 2011-06-07 12:48:07 +0300 |
commit | ab948f7e6d437dddd070000f36489d7e983eb4ad (patch) | |
tree | 8a9508658adce7f821016ea467458ddd5a6f6b1c /libpcsxcore | |
parent | 808a13bdcc83e7b0dec878bbcfc7774e2029b724 (diff) | |
download | pcsx_rearmed-ab948f7e6d437dddd070000f36489d7e983eb4ad.tar.gz pcsx_rearmed-ab948f7e6d437dddd070000f36489d7e983eb4ad.tar.bz2 pcsx_rearmed-ab948f7e6d437dddd070000f36489d7e983eb4ad.zip |
enable Wall warnings by default
still disable it in some cases (instead of fixing) to avoid
drifting from upstream projects too much.
Diffstat (limited to 'libpcsxcore')
-rw-r--r-- | libpcsxcore/cdriso.c | 4 | ||||
-rw-r--r-- | libpcsxcore/ppf.c | 3 | ||||
-rw-r--r-- | libpcsxcore/ppf.h | 2 | ||||
-rw-r--r-- | libpcsxcore/psxcommon.c | 7 | ||||
-rw-r--r-- | libpcsxcore/psxcounters.c | 2 | ||||
-rw-r--r-- | libpcsxcore/sio.c | 2 | ||||
-rw-r--r-- | libpcsxcore/socket.c | 2 |
7 files changed, 14 insertions, 8 deletions
diff --git a/libpcsxcore/cdriso.c b/libpcsxcore/cdriso.c index 2d371dd..eb92281 100644 --- a/libpcsxcore/cdriso.c +++ b/libpcsxcore/cdriso.c @@ -833,7 +833,7 @@ static long CALLBACK ISOgetTD(unsigned char track, unsigned char *buffer) { unsigned int sect; unsigned char time[3]; sect = msf2sec(ti[numtracks].start) + msf2sec(ti[numtracks].length); - sec2msf(sect, time); + sec2msf(sect, (char *)time); buffer[2] = time[0]; buffer[1] = time[1]; buffer[0] = time[2]; @@ -913,7 +913,7 @@ static long CALLBACK ISOplay(unsigned char *time) { return 0; // find the track - sect = msf2sec(time); + sect = msf2sec((char *)time); for (i = numtracks; i > 1; i--) if (msf2sec(ti[i].start) <= sect + 2 * 75) break; diff --git a/libpcsxcore/ppf.c b/libpcsxcore/ppf.c index 268ed1c..ee32d8b 100644 --- a/libpcsxcore/ppf.c +++ b/libpcsxcore/ppf.c @@ -335,7 +335,7 @@ void BuildPPFCache() { unsigned char *sbi_sectors; int LoadSBI(const char *fname, int sector_count) { - char buffer[16], sbifile[MAXPATHLEN]; + char buffer[16]; FILE *sbihandle; u8 sbitime[3]; int s; @@ -344,7 +344,6 @@ int LoadSBI(const char *fname, int sector_count) { if (sbihandle == NULL) return -1; -if (sbi_sectors != NULL) printf("sbi_sectors?\n"); sbi_sectors = calloc(1, sector_count / 8); if (sbi_sectors == NULL) return -1; diff --git a/libpcsxcore/ppf.h b/libpcsxcore/ppf.h index fdb11eb..aad85c9 100644 --- a/libpcsxcore/ppf.h +++ b/libpcsxcore/ppf.h @@ -32,6 +32,8 @@ void UnloadSBI(void); extern unsigned char *sbi_sectors; +#include "cdrom.h" + static inline int CheckSBI(const u8 *t) { int s; diff --git a/libpcsxcore/psxcommon.c b/libpcsxcore/psxcommon.c index ea655df..8313304 100644 --- a/libpcsxcore/psxcommon.c +++ b/libpcsxcore/psxcommon.c @@ -57,7 +57,12 @@ void EmuUpdate() { SysUpdate(); ApplyCheats(); - pl_frame_limit(); + + // reamed hack + { + extern void pl_frame_limit(void); + pl_frame_limit(); + } } void __Log(char *fmt, ...) { diff --git a/libpcsxcore/psxcounters.c b/libpcsxcore/psxcounters.c index 1c514e8..f6c1bc4 100644 --- a/libpcsxcore/psxcounters.c +++ b/libpcsxcore/psxcounters.c @@ -100,7 +100,7 @@ void verboseLog( s32 level, const char *str, ... ) vsprintf( buf, str, va ); va_end( va ); - printf( buf ); + printf( "%s", buf ); fflush( stdout ); } } diff --git a/libpcsxcore/sio.c b/libpcsxcore/sio.c index 8a30797..df130e8 100644 --- a/libpcsxcore/sio.c +++ b/libpcsxcore/sio.c @@ -673,7 +673,7 @@ void ConvertMcd(char *mcd, char *data) { } void GetMcdBlockInfo(int mcd, int block, McdBlock *Info) { - unsigned char *data = NULL, *ptr, *str, *sstr; + char *data = NULL, *ptr, *str, *sstr; unsigned short clut[16]; unsigned short c; int i, x; diff --git a/libpcsxcore/socket.c b/libpcsxcore/socket.c index 2e0dc87..31f82e2 100644 --- a/libpcsxcore/socket.c +++ b/libpcsxcore/socket.c @@ -190,7 +190,7 @@ int ReadSocket(char * buffer, int len) { } int RawReadSocket(char * buffer, int len) { - int r; + int r = 0; int mlen = len < ptr ? len : ptr; if (!client_socket) |