From: otto Date: Tue, 12 Dec 2017 19:08:57 +0000 (+0000) Subject: Use bn_checkp() always; from kshe X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=4ac087679afd910ee4d05af5e53c800f1bb46383;p=openbsd Use bn_checkp() always; from kshe --- diff --git a/usr.bin/dc/mem.c b/usr.bin/dc/mem.c index 7359d48e7ae..db0abfe73e9 100644 --- a/usr.bin/dc/mem.c +++ b/usr.bin/dc/mem.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mem.c,v 1.8 2017/12/07 06:34:05 otto Exp $ */ +/* $OpenBSD: mem.c,v 1.9 2017/12/12 19:08:57 otto Exp $ */ /* * Copyright (c) 2003, Otto Moerbeek @@ -32,8 +32,7 @@ new_number(void) n = bmalloc(sizeof(*n)); n->scale = 0; n->number = BN_new(); - if (n->number == NULL) - err(1, NULL); + bn_checkp(n->number); return n; }