X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/60be9c406252ada31f35dafcb34d9559e70d6cc2..b6dde5ff6f208b83545a4b4e9e81712d0d8617a1:/src/smpi/include/smpi_keyvals.hpp diff --git a/src/smpi/include/smpi_keyvals.hpp b/src/smpi/include/smpi_keyvals.hpp index dc7dd35160..71bcae82e2 100644 --- a/src/smpi/include/smpi_keyvals.hpp +++ b/src/smpi/include/smpi_keyvals.hpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2010-2019. The SimGrid Team. All rights reserved. */ +/* Copyright (c) 2010-2020. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ @@ -56,7 +56,8 @@ class Keyval{ template int attr_delete(int keyval); template int attr_get(int keyval, void* attr_value, int* flag); template int attr_put(int keyval, void* attr_value); - template static int call_deleter(T* obj, smpi_key_elem elem, int keyval, void * value, int* flag); + template + static int call_deleter(T* obj, const s_smpi_key_elem_t* elem, int keyval, void* value, int* flag); template void cleanup_attr(); }; @@ -112,7 +113,7 @@ template int Keyval::attr_delete(int keyval){ template int Keyval::attr_get(int keyval, void* attr_value, int* flag){ - smpi_key_elem elem = T::keyvals_.at(keyval); + const s_smpi_key_elem_t* elem = T::keyvals_.at(keyval); if(elem==nullptr) return MPI_ERR_ARG; if(attributes()->empty()){ @@ -158,7 +159,7 @@ template void Keyval::cleanup_attr(){ call_deleter((T*)this, elem, it.first,it.second,&flag); } } else { - //already deleted, not a problem; + // already deleted, not a problem flag=0; } }