Replace tests on packed words with tests on strings.
authorJason S. Ninneman <jsn@mbar.us>
Tue, 11 Jul 2017 15:52:50 +0000 (08:52 -0700)
committerEric S. Raymond <esr@thyrsus.com>
Tue, 11 Jul 2017 23:14:38 +0000 (23:14 +0000)
main.c

diff --git a/main.c b/main.c
index f24c5bc4162cb6480b3f232d69f338b86d663204..8f3549e97dfc975c91ca4d76d6861b5fd91f5e46 100644 (file)
--- a/main.c
+++ b/main.c
@@ -1137,11 +1137,11 @@ Lclosecheck:
                 command.wd1 = token_to_packed("CATCH");
         }
 Lookup:
-        if (wordeq(command.wd1, token_to_packed("WEST"))) {
+        if (strncasecmp(command.raw1, "west", sizeof("west")) == 0) {
             if (++game.iwest == 10)
                 rspeak(W_IS_WEST);
         }
-        if (wordeq(command.wd1, token_to_packed("GO")) && !wordempty(command.wd2)) {
+        if (strncasecmp(command.raw1, "go", sizeof("go")) == 0 && !wordempty(command.wd2)) {
             if (++game.igo == 10)
                 rspeak(GO_UNNEEDED);
         }