summaryrefslogtreecommitdiffstats
path: root/usr.bin/m4
diff options
context:
space:
mode:
authoraraujo <araujo@FreeBSD.org>2016-04-18 07:09:34 +0000
committeraraujo <araujo@FreeBSD.org>2016-04-18 07:09:34 +0000
commit45973d9d158dfe53cf0299b6e8f21545186c6c95 (patch)
tree72d0195fe2cd71f981220db492f56346d6528b44 /usr.bin/m4
parentb2f244e71eb0815053ac5d645349498f4f1bd205 (diff)
downloadFreeBSD-src-45973d9d158dfe53cf0299b6e8f21545186c6c95.zip
FreeBSD-src-45973d9d158dfe53cf0299b6e8f21545186c6c95.tar.gz
Use NULL instead of 0 for pointers.
fopen(3) will return NULL in case it cannot open the STREAM. MFC after: 2 weeks.
Diffstat (limited to 'usr.bin/m4')
-rw-r--r--usr.bin/m4/gnum4.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/m4/gnum4.c b/usr.bin/m4/gnum4.c
index dcccf3b..61f96d4 100644
--- a/usr.bin/m4/gnum4.c
+++ b/usr.bin/m4/gnum4.c
@@ -129,7 +129,7 @@ dopath(struct input_file *i, const char *filename)
for (pe = first; pe; pe = pe->next) {
snprintf(path, sizeof(path), "%s/%s", pe->name, filename);
- if ((f = fopen(path, "r")) != 0) {
+ if ((f = fopen(path, "r")) != NULL) {
set_input(i, f, path);
return i;
}
OpenPOWER on IntegriCloud