Add and use CZNC::GetUptime() for getting the current uptime in human readable

git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1098 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
psychon
2008-06-19 08:39:10 +00:00
parent d397cb8ad2
commit bcf59c56ea
3 changed files with 7 additions and 4 deletions
+5
View File
@@ -94,6 +94,11 @@ CString CZNC::GetTag(bool bIncludeVersion) {
return szBuf;
}
CString CZNC::GetUptime() {
time_t now = time(NULL);
return CString(now - TimeStarted()) + " seconds";
}
bool CZNC::OnBoot() {
#ifdef _MODULES
if (!GetModules().OnBoot()) {