Fix MSVC warnings

This commit is contained in:
twinaphex 2019-07-22 20:16:27 +02:00
parent 847a92c2a7
commit f3eb48d1f5
3 changed files with 4 additions and 6 deletions

View File

@ -290,7 +290,6 @@ static void *xa_init(const char *device, unsigned rate, unsigned latency,
static ssize_t xa_write(void *data, const void *buf, size_t size)
{
size_t ret;
unsigned bytes;
xa_t *xa = (xa_t*)data;
xaudio2_t *handle = xa->xa;

View File

@ -40,7 +40,7 @@ static void media_zero_trailing_spaces(char *buf, size_t len)
static bool media_skip_spaces(const char **buf, size_t len)
{
bool found = false;
int i;
unsigned i;
if (!buf || !*buf)
return false;
@ -245,9 +245,8 @@ bool media_detect_cd_info(const char *path, media_detect_cd_info_t *info)
/* Primary Volume Descriptor fields of ISO9660 */
else if (!memcmp(buf + offset + (16 * sector_size), "\1CD001\1\0PLAYSTATION", 19))
{
const char *title_pos;
const char *serial_pos;
bool title_found = false;
const char *title_pos = NULL;
bool title_found = false;
info->system_id = MEDIA_CD_SYSTEM_PSX;

View File

@ -340,7 +340,7 @@ int64_t retro_vfs_file_read_cdrom(libretro_vfs_implementation_file *stream,
if (string_is_equal_noncase(ext, "cue"))
{
if (len < stream->cdrom.cue_len - stream->cdrom.byte_pos)
if (len < (unsigned)(stream->cdrom.cue_len - stream->cdrom.byte_pos))
{
#ifdef CDROM_DEBUG
printf("[CDROM] Read: Reading %" PRIu64 " bytes from cuesheet starting at %" PRIu64 "...\n", len, stream->cdrom.byte_pos);