From 9410de0d270dd06df2e562b92a83b04adff3fc97 Mon Sep 17 00:00:00 2001 From: Gilles Gouaillardet Date: Mon, 21 May 2018 13:31:44 +0900 Subject: [PATCH] opal/util: plug a memory leak in the opal_infosubscriber_t destructor Signed-off-by: Gilles Gouaillardet (cherry picked from commit open-mpi/ompi@7556dd0abbee7d8af6da77be472e25a16e4ee2f5) --- opal/util/info_subscriber.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/opal/util/info_subscriber.c b/opal/util/info_subscriber.c index 348194c89b..5b0544e36d 100644 --- a/opal/util/info_subscriber.c +++ b/opal/util/info_subscriber.c @@ -14,7 +14,7 @@ * Copyright (c) 2009 Sun Microsystems, Inc. All rights reserved. * Copyright (c) 2012-2017 Los Alamos National Security, LLC. All rights * reserved. - * Copyright (c) 2015 Research Organization for Information Science + * Copyright (c) 2015-2018 Research Organization for Information Science * and Technology (RIST). All rights reserved. * Copyright (c) 2016-2018 IBM Corporation. All rights reserved. * Copyright (c) 2017-2018 Intel, Inc. All rights reserved. @@ -97,6 +97,10 @@ static void infosubscriber_destruct(opal_infosubscriber_t *obj) { } OBJ_DESTRUCT(&obj->s_subscriber_table); + + if (NULL != obj->s_info) { + OBJ_RELEASE(obj->s_info); + } } static void opal_callback_list_item_destruct(opal_callback_list_item_t *obj) {