Commit 608f52eb authored by Jim Harris's avatar Jim Harris
Browse files

app/iscsi_top: use MAP_FAILED for mmap() check instead of NULL



Signed-off-by: default avatarJim Harris <james.r.harris@intel.com>
Change-Id: I69214fa90e9e7c6e789e04c0b5d4540a4a7d4b7f
parent d35443d4
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -167,7 +167,7 @@ int main(int argc, char **argv)
	}

	history_ptr = mmap(NULL, sizeof(*histories), PROT_READ, MAP_SHARED, history_fd, 0);
	if (history_ptr == NULL) {
	if (history_ptr == MAP_FAILED) {
		fprintf(stderr, "Unable to mmap history shm\n");
		exit(1);
	}