Use NULL instead of 0 for pointers.

strchr(3) will return NULL if the character does not appear in the
string.

MFC after:	2 weeks.
This commit is contained in:
Marcelo Araujo 2016-04-18 07:40:36 +00:00
parent 3e41d09d08
commit fb6a35935a
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=298193

View File

@ -781,7 +781,7 @@ getasciilabel(FILE *f, struct disklabel *lp)
lp->d_sbsize = 0; /* XXX */
while (fgets(line, sizeof(line) - 1, f)) {
lineno++;
if ((cp = strchr(line,'\n')) != 0)
if ((cp = strchr(line,'\n')) != NULL)
*cp = '\0';
cp = skip(line);
if (cp == NULL)