From 141a773f47efb475e534ce4eacea6b6c0937101a Mon Sep 17 00:00:00 2001 From: tobhe Date: Thu, 18 Feb 2021 21:39:36 +0000 Subject: [PATCH] Remove redundant ibuf_release. msg_ke is always NULL because of the duplicate check above. --- sbin/iked/ikev2_pld.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/sbin/iked/ikev2_pld.c b/sbin/iked/ikev2_pld.c index d8551e1f8db..ad407f7293d 100644 --- a/sbin/iked/ikev2_pld.c +++ b/sbin/iked/ikev2_pld.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ikev2_pld.c,v 1.115 2021/02/16 21:07:43 tobhe Exp $ */ +/* $OpenBSD: ikev2_pld.c,v 1.116 2021/02/18 21:39:36 tobhe Exp $ */ /* * Copyright (c) 2019 Tobias Heider @@ -688,7 +688,6 @@ ikev2_pld_ke(struct iked *env, struct ikev2_payload *pld, log_info("%s: duplicate KE payload", __func__); return (-1); } - ibuf_release(msg->msg_parent->msg_ke); if ((msg->msg_parent->msg_ke = ibuf_new(buf, len)) == NULL) { log_debug("%s: failed to get exchange", __func__); return (-1); -- 2.20.1