From: Marco van den Heuvel Date: Sun, 29 Nov 2015 18:50:22 +0000 (-0800) Subject: Changed according to suggestions. X-Git-Tag: V2.16~179^2~5 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=97c9ed327387fd07c7161801aed07505ff21dacd;p=cc65 Changed according to suggestions. --- diff --git a/testcode/lib/em-test.c b/testcode/lib/em-test.c index 6877eb352..4a08d57c4 100644 --- a/testcode/lib/em-test.c +++ b/testcode/lib/em-test.c @@ -106,7 +106,7 @@ static emd_test_t drivers[] = { { '0', "CBM6x0/7x0 RAM in bank 2", "cbm610-ram.emd" }, #endif - { NULL, NULL } + { 0, NULL, NULL } }; int main (void) @@ -123,13 +123,13 @@ int main (void) clrscr (); cputs ("Which RAM exp to test?\r\n\r\n"); - for (index = 0; drivers[index].displayname; ++index) { + for (index = 0; drivers[index].key; ++index) { cprintf("%c: %s\r\n", drivers[index].key, drivers[index].displayname); } - while (valid_key == -1) { + while (valid_key < 0) { key = cgetc(); - for (index = 0; drivers[index].displayname && valid_key == -1; ++index) { + for (index = 0; drivers[index].key && valid_key < 0; ++index) { if (key == drivers[index].key) { valid_key = index; }