Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Const.
authorArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Fri, 16 Oct 2020 07:11:41 +0000 (09:11 +0200)
committerArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Fri, 16 Oct 2020 07:30:18 +0000 (09:30 +0200)
src/xbt/xbt_log_appender_file.cpp

index 33ab714..577e934 100644 (file)
@@ -75,8 +75,8 @@ static void open_append2_file(xbt_log_append2_file_t data){
     char* sep=strchr(pre,'%');
     if(!sep)
       sep=pre+strlen(pre);
-    char* post=sep+1;
-    *sep='\0';
+    const char* post    = sep + 1;
+    *sep                = '\0';
     std::string newname = pre + std::to_string(data->count) + post;
     data->count++;
     data->file = fopen(newname.c_str(), "w");