diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2002-07-31 09:19:41 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2002-07-31 09:19:41 +0000 |
commit | a6d4786f0d6839f7b3cb34bb77744b9932b73197 (patch) | |
tree | 2406023e05af7e6c91b0732d91012f0d2e491729 /usr.sbin/named | |
parent | a3c74a24f70a546b0457d0d93a3e22be904b3e31 (diff) |
sync to libc calloc()
Diffstat (limited to 'usr.sbin/named')
-rw-r--r-- | usr.sbin/named/named/storage.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/named/named/storage.c b/usr.sbin/named/named/storage.c index b71f8a41966..a9d9b37a3ac 100644 --- a/usr.sbin/named/named/storage.c +++ b/usr.sbin/named/named/storage.c @@ -1,4 +1,4 @@ -/* $OpenBSD: storage.c,v 1.6 2002/07/30 22:39:35 deraadt Exp $ */ +/* $OpenBSD: storage.c,v 1.7 2002/07/31 09:19:40 deraadt Exp $ */ /* * ++Copyright++ 1985, 1989 @@ -192,7 +192,7 @@ calloc(num, size) { register char *p; - if (SIZE_T_MAX / num < size) { + if (num && size && SIZE_T_MAX / num < size) { errno = ENOMEM; return NULL; } |