firewave: "And here's a few MESS/core ones I overlooked yesterday:

s:\svn\mame\src\emu\cpu\dsp16\dsp16ops.inc(365) : warning C6316: Incorrect operator:  tested expression is constant and non-zero.  Use bitwise-and to determine whether bits are set.
s:\svn\mame\src\emu\cpu\es5510\es5510.c(608) : warning C6201: Index '255' is out of valid index range '0' to '254' for possibly stack allocated buffer 'is_written'.
s:\svn\mame\src\emu\cpu\es5510\es5510.c(608) : warning C6201: Index '255' is out of valid index range '0' to '254' for possibly stack allocated buffer 'is_read'.
s:\svn\mame\src\emu\cpu\es5510\es5510.c(609) : warning C6201: Index '255' is out of valid index range '0' to '254' for possibly stack allocated buffer 'name'.
s:\svn\mame\src\emu\cpu\es5510\es5510.c(666) : warning C6201: Index '255' is out of valid index range '0' to '254' for possibly stack allocated buffer 'name'.
s:\svn\mame\src\emu\cpu\m68000\m68kcpu.c(681) : warning C6314: Incorrect order of operations:  bitwise-or has higher precedence than the conditional-expression operator.  Add parentheses to clarify intent.

"
This commit is contained in:
Michaël Banaan Ananas 2014-04-04 16:24:13 +00:00
parent a1cd7333a1
commit c908c329a9
3 changed files with 5 additions and 6 deletions

View File

@ -361,8 +361,8 @@ void dsp16_device::executeF1Field(const UINT8& F1, const UINT8& D, const UINT8&
// TODO
// LMV (mathematical overflow)
if ((result | U64(0xf00000000)) != U64(0xf00000000) &&
(result | U64(0xf00000000)) != U64(0x000000000))
if ((result & U64(0xf00000000)) != U64(0xf00000000) &&
(result & U64(0xf00000000)) != U64(0x000000000))
m_psw |= 0x1000;
else
m_psw &= (~0x1000);

View File

@ -600,8 +600,8 @@ void es5510_device::list_program(void(p)(const char *, ...)) {
LOG(("ES5501: Starting!\n"));
char buf[1024];
bool is_written[0xff], is_read[0xff];
char name[0xff][16];
bool is_written[0x100], is_read[0x100];
char name[0x100][16];
int addr;
for (int i = 0; i < 0x100; i++) {

View File

@ -677,8 +677,7 @@ static void m68k_presave(m68000_base_device *m68k)
static void m68k_postload(m68000_base_device *m68k)
{
m68ki_set_sr_noint_nosp(m68k, m68k->save_sr);
m68k->stopped = m68k->save_stopped ? STOP_LEVEL_STOP : 0
| m68k->save_halted ? STOP_LEVEL_HALT : 0;
m68k->stopped = (m68k->save_stopped ? STOP_LEVEL_STOP : 0) | (m68k->save_halted ? STOP_LEVEL_HALT : 0);
m68ki_jump(m68k, REG_PC(m68k));
}