Merge pull request #1370 from Diapolo/add_startuptime_to_log
add client startup time as an entry to debug.log
This commit is contained in:
commit
1e07068adf
@ -414,6 +414,7 @@ bool AppInit2()
|
|||||||
ShrinkDebugFile();
|
ShrinkDebugFile();
|
||||||
printf("\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n");
|
printf("\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n");
|
||||||
printf("Bitcoin version %s (%s)\n", FormatFullVersion().c_str(), CLIENT_DATE.c_str());
|
printf("Bitcoin version %s (%s)\n", FormatFullVersion().c_str(), CLIENT_DATE.c_str());
|
||||||
|
printf("Startup time: %s\n", DateTimeStrFormat("%x %H:%M:%S", GetTime()).c_str());
|
||||||
printf("Default data directory %s\n", GetDefaultDataDir().string().c_str());
|
printf("Default data directory %s\n", GetDefaultDataDir().string().c_str());
|
||||||
std::ostringstream strErrors;
|
std::ostringstream strErrors;
|
||||||
|
|
||||||
|
@ -130,9 +130,9 @@ QString ClientModel::clientName() const
|
|||||||
return QString::fromStdString(CLIENT_NAME);
|
return QString::fromStdString(CLIENT_NAME);
|
||||||
}
|
}
|
||||||
|
|
||||||
QDateTime ClientModel::formatClientStartupTime() const
|
QString ClientModel::formatClientStartupTime() const
|
||||||
{
|
{
|
||||||
return QDateTime::fromTime_t(nClientStartupTime);
|
return QDateTime::fromTime_t(nClientStartupTime).toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Handlers for core signals
|
// Handlers for core signals
|
||||||
|
@ -41,7 +41,7 @@ public:
|
|||||||
QString formatFullVersion() const;
|
QString formatFullVersion() const;
|
||||||
QString formatBuildDate() const;
|
QString formatBuildDate() const;
|
||||||
QString clientName() const;
|
QString clientName() const;
|
||||||
QDateTime formatClientStartupTime() const;
|
QString formatClientStartupTime() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
OptionsModel *optionsModel;
|
OptionsModel *optionsModel;
|
||||||
|
@ -163,7 +163,7 @@ void RPCConsole::setClientModel(ClientModel *model)
|
|||||||
ui->clientVersion->setText(model->formatFullVersion());
|
ui->clientVersion->setText(model->formatFullVersion());
|
||||||
ui->clientName->setText(model->clientName());
|
ui->clientName->setText(model->clientName());
|
||||||
ui->buildDate->setText(model->formatBuildDate());
|
ui->buildDate->setText(model->formatBuildDate());
|
||||||
ui->startupTime->setText(model->formatClientStartupTime().toString());
|
ui->startupTime->setText(model->formatClientStartupTime());
|
||||||
|
|
||||||
setNumConnections(model->getNumConnections());
|
setNumConnections(model->getNumConnections());
|
||||||
ui->isTestNet->setChecked(model->isTestNet());
|
ui->isTestNet->setChecked(model->isTestNet());
|
||||||
|
Loading…
Reference in New Issue
Block a user