mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
Revert "tests: use put_time"
This reverts commit b4af2571db
.
std::put_time is a relatively new feature so breaks builds on older
systems.
This commit is contained in:
parent
2dc6c3d236
commit
9036862357
@ -319,9 +319,12 @@ struct Journal {
|
||||
of << ru->second;
|
||||
else {
|
||||
struct tm time_info;
|
||||
char buf[64];
|
||||
time_t t = time( 0 );
|
||||
if (localtime_r(&t, &time_info))
|
||||
of << "--- " << std::put_time( &time_info, "%F %T" ) << " ---";
|
||||
if (localtime_r(&t, &time_info)) {
|
||||
strftime(buf, sizeof(buf), "%F %T", &time_info);
|
||||
of << "--- " << buf << " ---";
|
||||
}
|
||||
}
|
||||
of << std::endl;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user