diff options
author | araujo <araujo@FreeBSD.org> | 2016-04-18 05:19:45 +0000 |
---|---|---|
committer | araujo <araujo@FreeBSD.org> | 2016-04-18 05:19:45 +0000 |
commit | 25333787db7b96c565f826f86cb864488835861f (patch) | |
tree | 19df4f8ca7fb76ab1db91557757f976110ec0b54 | |
parent | d2ff81490f54ee7dce8300a6be73933fc2b787d8 (diff) | |
download | FreeBSD-src-25333787db7b96c565f826f86cb864488835861f.zip FreeBSD-src-25333787db7b96c565f826f86cb864488835861f.tar.gz |
The malloc will return NULL if it can't allocate memory.
MFC after: 2 weeks.
-rw-r--r-- | usr.sbin/makefs/ffs/mkfs.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/makefs/ffs/mkfs.c b/usr.sbin/makefs/ffs/mkfs.c index b1bdd09..dfdaf57 100644 --- a/usr.sbin/makefs/ffs/mkfs.c +++ b/usr.sbin/makefs/ffs/mkfs.c @@ -492,7 +492,7 @@ ffs_mkfs(const char *fsys, const fsinfo_t *fsopts) iobufsize = SBLOCKSIZE + 3 * sblock.fs_bsize; else iobufsize = 4 * sblock.fs_bsize; - if ((iobuf = malloc(iobufsize)) == 0) { + if ((iobuf = malloc(iobufsize)) == NULL) { printf("Cannot allocate I/O buffer\n"); exit(38); } |