Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
various cleanups in actors/processes
[simgrid.git] / src / smpi / smpi_f2c.cpp
index 978722d..df584b4 100644 (file)
@@ -80,8 +80,8 @@ F2C* F2C::f2c(int id){
   if(f2c_lookup_==nullptr){
     f2c_lookup_=xbt_dict_new_homogeneous(nullptr);
   }
-  char key[KEY_SIZE];
   if(id >= 0){
+    char key[KEY_SIZE];
     return static_cast<F2C*>(xbt_dict_get_or_null(f2c_lookup_, get_key(key, id)));
   }else
     return NULL;