fix scoping bug in 'maxref' variable

This commit is contained in:
zeromus 2015-09-13 18:19:08 +00:00
parent 05a7ab1f33
commit 090fc71eab
1 changed files with 2 additions and 1 deletions

View File

@ -1813,7 +1813,8 @@ int FCEUPPU_Loop(int skip) {
if (MMC5Hack) MMC5_hb(scanline);
//deemph nonsense, kept for complicated reasons (see SetNESDeemph_OldHacky implementation)
for (int x = 1, max = 0, maxref = 0; x < 7; x++) {
int maxref = 0;
for (int x = 1, max = 0; x < 7; x++) {
if (deempcnt[x] > max) {
max = deempcnt[x];
maxref = x;