1
1

btl/vader: fix finalize sequence

free the component mpool in mca_btl_vader_component_close()
and after freeing soem objects that depend on it such as
mca_btl_vader_component.vader_frags_user

Thanks Christoph Niethammer for reporting this.

Refs. open-mpi/ompi#6524

Signed-off-by: Gilles Gouaillardet <gilles@rist.or.jp>

(cherry picked from commit open-mpi/ompi@77060cad07)
Этот коммит содержится в:
Gilles Gouaillardet 2019-03-27 11:55:27 +09:00
родитель 5d4c9b444a
Коммит 70a864fce3
2 изменённых файлов: 9 добавлений и 9 удалений

Просмотреть файл

@ -16,8 +16,8 @@
* All rights reserved. * All rights reserved.
* Copyright (c) 2011 NVIDIA Corporation. All rights reserved. * Copyright (c) 2011 NVIDIA Corporation. All rights reserved.
* Copyright (c) 2014-2018 Intel, Inc. All rights reserved. * Copyright (c) 2014-2018 Intel, Inc. All rights reserved.
* Copyright (c) 2014-2018 Research Organization for Information Science * Copyright (c) 2014-2019 Research Organization for Information Science
* and Technology (RIST). All rights reserved. * and Technology (RIST). All rights reserved.
* Copyright (c) 2018 Amazon.com, Inc. or its affiliates. All Rights reserved. * Copyright (c) 2018 Amazon.com, Inc. or its affiliates. All Rights reserved.
* Copyright (c) 2018 Triad National Security, LLC. All rights * Copyright (c) 2018 Triad National Security, LLC. All rights
* reserved. * reserved.
@ -341,6 +341,11 @@ static int mca_btl_vader_component_close(void)
mca_btl_vader_knem_fini (); mca_btl_vader_knem_fini ();
#endif #endif
if (mca_btl_vader_component.mpool) {
mca_btl_vader_component.mpool->mpool_finalize (mca_btl_vader_component.mpool);
mca_btl_vader_component.mpool = NULL;
}
return OPAL_SUCCESS; return OPAL_SUCCESS;
} }

Просмотреть файл

@ -15,8 +15,8 @@
* Copyright (c) 2010-2015 Los Alamos National Security, LLC. All rights * Copyright (c) 2010-2015 Los Alamos National Security, LLC. All rights
* reserved. * reserved.
* Copyright (c) 2014-2015 Intel, Inc. All rights reserved. * Copyright (c) 2014-2015 Intel, Inc. All rights reserved.
* Copyright (c) 2014-2015 Research Organization for Information Science * Copyright (c) 2014-2019 Research Organization for Information Science
* and Technology (RIST). All rights reserved. * and Technology (RIST). All rights reserved.
* Copyright (c) 2018-2019 Triad National Security, LLC. All rights * Copyright (c) 2018-2019 Triad National Security, LLC. All rights
* reserved. * reserved.
* $COPYRIGHT$ * $COPYRIGHT$
@ -380,11 +380,6 @@ static int vader_finalize(struct mca_btl_base_module_t *btl)
} }
#endif #endif
if (component->mpool) {
component->mpool->mpool_finalize (component->mpool);
component->mpool = NULL;
}
return OPAL_SUCCESS; return OPAL_SUCCESS;
} }