summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2017-01-30 13:39:19 +0100
committerRalf Baechle <ralf@linux-mips.org>2017-02-06 23:43:46 +0100
commit1ec1a157d9f0997febd3cdce6dc5a98688a8f9a0 (patch)
treef0af3e1d0915d1c8c36a8906ad1aecf8fa2ccfd8
parent70a009216d4dd259ceea2788bbf93030211170b4 (diff)
axspawn: Fix use of 0 instead of NULL as a pointer value.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
-rw-r--r--ax25/axspawn.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/ax25/axspawn.c b/ax25/axspawn.c
index 413b554..8c9dae8 100644
--- a/ax25/axspawn.c
+++ b/ax25/axspawn.c
@@ -821,7 +821,7 @@ static void kick_wqueue(int dummy)
itv.it_interval.tv_sec = 0;
itv.it_interval.tv_usec = 0;
- setitimer(ITIMER_REAL, &itv, 0);
+ setitimer(ITIMER_REAL, &itv, NULL);
signal(SIGALRM, kick_wqueue);
}
@@ -1403,7 +1403,7 @@ int main(int argc, char **argv)
int pwtype = 0;
int pwtype_orig = 0;
char prompt[20];
- char *pwd = 0;
+ char *pwd = NULL;
*prompt = 0;
@@ -1646,7 +1646,7 @@ again:
pwtype = (pwtype_orig & ~PW_MD5);
if (pwd)
free(pwd);
- pwd = 0;
+ pwd = NULL;
goto again;
}
if (!strstr(buf, pass_want)) {
@@ -1657,7 +1657,7 @@ again:
}
if (pwd)
free(pwd);
- pwd = 0;
+ pwd = NULL;
} else {
if (pw->pw_uid == 0 || pw->pw_gid == 0) {
sprintf(buf, "Sorry, root logins are only allowed with md5- or baycom-password!\r");
@@ -1669,7 +1669,7 @@ again:
}
if (pwd)
free(pwd);
- pwd = 0;
+ pwd = NULL;
/*
* associate UID with callsign (or vice versa?)
@@ -1748,7 +1748,7 @@ again:
if (dumb_embedded_system) {
int ret = -1;
- char *p = 0;
+ char *p = NULL;
chown(ptyslave, pw->pw_uid, 0);
chmod(ptyslave, 0622);
@@ -1779,7 +1779,7 @@ again:
if ((p = strdup(p)))
*p = '-';
- } else p = 0;
+ } else p = NULL;
}
if (!p)
p = shell;