use utils::trim() to remove extra whitespace from ctime() output.
This commit is contained in:
@ -240,8 +240,7 @@ void generate_yaml_file(const char *outfile, const TestConfig &config)
|
||||
|
||||
// date_generated
|
||||
std::time_t now = time(NULL);
|
||||
block = ctime(&now);
|
||||
block = block.substr(0, block.find("\n") - 1);
|
||||
block = utils::trim(ctime(&now));
|
||||
writer.emit("date_generated", block);
|
||||
|
||||
// epsilon
|
||||
|
||||
@ -240,8 +240,7 @@ void generate_yaml_file(const char *outfile, const TestConfig &config)
|
||||
|
||||
// date_generated
|
||||
std::time_t now = time(NULL);
|
||||
block = ctime(&now);
|
||||
block = block.substr(0, block.find("\n") - 1);
|
||||
block = utils::trim(ctime(&now));
|
||||
writer.emit("date_generated", block);
|
||||
|
||||
// epsilon
|
||||
|
||||
@ -249,8 +249,7 @@ void generate_yaml_file(const char *outfile, const TestConfig &config)
|
||||
|
||||
// date_generated
|
||||
std::time_t now = time(NULL);
|
||||
block = ctime(&now);
|
||||
block = block.substr(0, block.find("\n") - 1);
|
||||
block = utils::trim(ctime(&now));
|
||||
writer.emit("date_generated", block);
|
||||
|
||||
// epsilon
|
||||
|
||||
@ -198,8 +198,7 @@ void generate_yaml_file(const char *outfile, const TestConfig &config)
|
||||
|
||||
// date_generated
|
||||
std::time_t now = time(NULL);
|
||||
block = ctime(&now);
|
||||
block = block.substr(0, block.find("\n") - 1);
|
||||
block = utils::trim(ctime(&now));
|
||||
writer.emit("date_generated", block);
|
||||
|
||||
// epsilon
|
||||
|
||||
@ -240,8 +240,7 @@ void generate_yaml_file(const char *outfile, const TestConfig &config)
|
||||
|
||||
// date_generated
|
||||
std::time_t now = time(NULL);
|
||||
block = ctime(&now);
|
||||
block = block.substr(0, block.find("\n") - 1);
|
||||
block = utils::trim(ctime(&now));
|
||||
writer.emit("date_generated", block);
|
||||
|
||||
// epsilon
|
||||
|
||||
@ -244,8 +244,7 @@ void generate_yaml_file(const char *outfile, const TestConfig &config)
|
||||
|
||||
// date_generated
|
||||
std::time_t now = time(NULL);
|
||||
block = ctime(&now);
|
||||
block = block.substr(0, block.find("\n") - 1);
|
||||
block = utils::trim(ctime(&now));
|
||||
writer.emit("date_generated", block);
|
||||
|
||||
// epsilon
|
||||
|
||||
Reference in New Issue
Block a user