Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Fix condition.
authorArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Mon, 25 Mar 2019 09:44:25 +0000 (10:44 +0100)
committerArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Mon, 25 Mar 2019 09:44:25 +0000 (10:44 +0100)
src/xbt/log.cpp

index dc91b53..18da689 100644 (file)
@@ -641,7 +641,7 @@ static void xbt_log_help_categories_rec(xbt_log_category_t category, const std::
     cats.push_back(cat);
 
   std::sort(begin(cats), end(cats),
-            [](xbt_log_category_t a, xbt_log_category_t b) { return strcmp(a->name, b->name) == -1; });
+            [](xbt_log_category_t a, xbt_log_category_t b) { return strcmp(a->name, b->name) < 0; });
 
   for (auto const& cat : cats) {
     printf("%s%s: %s\n", this_prefix.c_str(), cat->name, cat->description);