=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/ssh/monitor_wrap.c,v retrieving revision 1.111 retrieving revision 1.112 diff -u -r1.111 -r1.112 --- src/usr.bin/ssh/monitor_wrap.c 2019/01/19 21:43:56 1.111 +++ src/usr.bin/ssh/monitor_wrap.c 2019/01/21 09:54:11 1.112 @@ -1,4 +1,4 @@ -/* $OpenBSD: monitor_wrap.c,v 1.111 2019/01/19 21:43:56 djm Exp $ */ +/* $OpenBSD: monitor_wrap.c,v 1.112 2019/01/21 09:54:11 djm Exp $ */ /* * Copyright 2002 Niels Provos * Copyright 2002 Markus Friedl @@ -197,12 +197,8 @@ if (success == 0) fatal("%s: MONITOR_ANS_MODULI failed", __func__); - if ((p = BN_new()) == NULL) - fatal("%s: BN_new failed", __func__); - if ((g = BN_new()) == NULL) - fatal("%s: BN_new failed", __func__); - if ((r = sshbuf_get_bignum2(m, p)) != 0 || - (r = sshbuf_get_bignum2(m, g)) != 0) + if ((r = sshbuf_get_bignum2(m, &p)) != 0 || + (r = sshbuf_get_bignum2(m, &g)) != 0) fatal("%s: buffer error: %s", __func__, ssh_err(r)); debug3("%s: remaining %zu", __func__, sshbuf_len(m));