From fd2d24eb2e9c2b70d3402d29d0ab1ac5c612425f Mon Sep 17 00:00:00 2001 From: "Michael S. Tsirkin" Date: Sun, 11 Mar 2007 10:08:40 +0200 Subject: [PATCH] Fixed warnings that were reported by sparse. Signed-off-by: Dotan Barak Signed-off-by: Michael S. Tsirkin --- mtcr.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mtcr.h b/mtcr.h index 9215668..07fc17d 100644 --- a/mtcr.h +++ b/mtcr.h @@ -335,7 +335,7 @@ mfile *mopen(const char *name) char file_name[]="/proc/bus/pci/0000:00/00.0"; mf=(mfile*)malloc(sizeof(mfile)); - if (!mf) return 0; + if (!mf) return NULL; //If device name starts with /proc/bus/pci we'll use configuration cycles if (!strncmp(name,"/proc/bus/pci/",strlen("/proc/bus/pci/"))) @@ -449,7 +449,7 @@ open_failed: #if CONFIG_ENABLE_MMAP find_failed: #endif - return 0; + return NULL; } #endif -- 2.46.0