From 45090be0fd8587e15339deb8bf8f6c44547df9d1 Mon Sep 17 00:00:00 2001 From: Sascha Wildner Date: Sun, 21 Jan 2018 00:22:27 +0100 Subject: [PATCH] {bs,quiz}(6): Compare pointers with NULL, not '\0'. --- games/bs/bs.c | 2 +- games/quiz/quiz.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/games/bs/bs.c b/games/bs/bs.c index 98c25fdfe0..0c6df74e94 100644 --- a/games/bs/bs.c +++ b/games/bs/bs.c @@ -191,7 +191,7 @@ intro(void) if(signal(SIGQUIT,SIG_IGN) != SIG_IGN) signal(SIGQUIT,sighandler); - if(tmpname != '\0') { + if(tmpname != NULL) { strcpy(name,tmpname); name[0] = toupper(name[0]); } else { diff --git a/games/quiz/quiz.c b/games/quiz/quiz.c index 10ef998094..f02eee9ea7 100644 --- a/games/quiz/quiz.c +++ b/games/quiz/quiz.c @@ -154,7 +154,7 @@ show_index(void) for (s = next_cat(qp->q_text); s; s = next_cat(s)) { if (!rxp_compile(s)) err("%s", rxperr); - if ((p = rxp_expand()) != '\0') + if ((p = rxp_expand()) != NULL) fprintf(pf, "%s ", p); } fprintf(pf, "\n"); -- 2.11.4.GIT