A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' into disk
[simgrid.git]
/
src
/
smpi
/
bindings
/
smpi_pmpi_info.cpp
diff --git
a/src/smpi/bindings/smpi_pmpi_info.cpp
b/src/smpi/bindings/smpi_pmpi_info.cpp
index
82634cf
..
0a694f2
100644
(file)
--- a/
src/smpi/bindings/smpi_pmpi_info.cpp
+++ b/
src/smpi/bindings/smpi_pmpi_info.cpp
@@
-34,8
+34,10
@@
int PMPI_Info_free( MPI_Info *info){
int PMPI_Info_get(MPI_Info info, const char *key,int valuelen, char *value, int *flag){
*flag=false;
int PMPI_Info_get(MPI_Info info, const char *key,int valuelen, char *value, int *flag){
*flag=false;
- if (info == nullptr ||
key == nullptr ||
valuelen <0)
+ if (info == nullptr || valuelen <0)
return MPI_ERR_ARG;
return MPI_ERR_ARG;
+ if (key == nullptr)
+ return MPI_ERR_INFO_KEY;
if (value == nullptr)
return MPI_ERR_INFO_VALUE;
return info->get(key, valuelen, value, flag);
if (value == nullptr)
return MPI_ERR_INFO_VALUE;
return info->get(key, valuelen, value, flag);
@@
-68,8
+70,12
@@
int PMPI_Info_get_nthkey( MPI_Info info, int n, char *key){
int PMPI_Info_get_valuelen( MPI_Info info, const char *key, int *valuelen, int *flag){
*flag=false;
int PMPI_Info_get_valuelen( MPI_Info info, const char *key, int *valuelen, int *flag){
*flag=false;
- if (info == nullptr
|| key == nullptr || valuelen==nullptr
)
+ if (info == nullptr)
return MPI_ERR_ARG;
return MPI_ERR_ARG;
+ if (key == nullptr)
+ return MPI_ERR_INFO_KEY;
+ if (valuelen == nullptr)
+ return MPI_ERR_INFO_VALUE;
return info->get_valuelen(key, valuelen, flag);
}
return info->get_valuelen(key, valuelen, flag);
}