X-Git-Url: https://bilbo.iut-bm.univ-fcomte.fr/and/gitweb/loba.git/blobdiff_plain/431ac6bd7924ab99473c9a621a25ab0c555c3e60..97a4b4dbf628a627e3c2d5689be89265f56074df:/communicator.cpp?ds=sidebyside diff --git a/communicator.cpp b/communicator.cpp index 8393515..054c98a 100644 --- a/communicator.cpp +++ b/communicator.cpp @@ -1,25 +1,26 @@ -#include "communicator.h" - #include #include #include #include #include + +XBT_LOG_EXTERNAL_DEFAULT_CATEGORY(comm); + #include "misc.h" #include "options.h" -XBT_LOG_EXTERNAL_DEFAULT_CATEGORY(comm); +#include "communicator.h" std::string message::to_string() { static const char* str[] = { "INFO", "CREDIT", "LOAD", "CTRL_CLOSE", "DATA_CLOSE" }; std::ostringstream oss; - oss << str[type] << " (" << amount << ")"; + oss << str[type] << ": " << amount; return oss.str(); } -const int communicator::send_count_before_flush = 128; +const int communicator::send_count_before_flush = 16; communicator::communicator() : host((hostdata* )MSG_host_get_data(MSG_host_self()))