Commit b893b3b33991c763a0b76f5ff0d6b6c72cb42fb2

Authored by Benjamin Renard
1 parent 48b6dc0d

Fix bug in script used to compare two TT

test/DD_Client/CSlimFixtures/ScriptTestAmdaCommandLine.cpp
... ... @@ -330,9 +330,12 @@ static char *dodiffTimeTable(const char *tt1, const char *tt2) {
330 330 return const_cast<char *>("0");
331 331 } else {
332 332 std::string error = str.str();
333   - std::vector<char> data(error.size() + 1);
334   - std::copy(error.begin(), error.end(), data.begin());
335   - return &data[0];
  333 + static char returnStr[1024];
  334 + sprintf (returnStr, "%1023s", error.c_str());
  335 + return const_cast<char *>(returnStr);
  336 + //std::vector<char> data(error.size() + 1);
  337 + //std::copy(error.begin(), error.end(), data.begin());
  338 + //return &data[0];
336 339 }
337 340 }
338 341  
... ...