From a5de41c600f3cbf587ca87d44e96c8466e46302c Mon Sep 17 00:00:00 2001 From: Marcelo Araujo Date: Thu, 14 Apr 2016 12:53:38 +0000 Subject: [PATCH] Use NULL instead of 0 for pointers. fopen(3) will return NULL in case it can't open the STREAM. --- usr.sbin/lmcconfig/lmcconfig.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.sbin/lmcconfig/lmcconfig.c b/usr.sbin/lmcconfig/lmcconfig.c index 7fbc2168e1ec..f720e634f8ff 100644 --- a/usr.sbin/lmcconfig/lmcconfig.c +++ b/usr.sbin/lmcconfig/lmcconfig.c @@ -2008,7 +2008,7 @@ load_xilinx(char *name) int c; if (verbose) printf("Load firmware from file %s...\n", name); - if ((f = fopen(name, "r")) == 0) + if ((f = fopen(name, "r")) == NULL) { perror("Failed to open file"); exit(1);