diff options
author | Adam <Adam@anope.org> | 2011-05-15 19:54:35 -0400 |
---|---|---|
committer | Adam <Adam@anope.org> | 2011-05-15 19:54:35 -0400 |
commit | 57327a5e33a41da44ee8b3c5da033dc655cabbc1 (patch) | |
tree | eb8292fcd02491acc703e4b9dba6e83f763367e3 | |
parent | 4a3c64291f683823a1f8977c00f57b57af577f03 (diff) |
Fixed akill log message when there is no expiry time
-rw-r--r-- | modules/core/os_akill.cpp | 2 | ||||
-rw-r--r-- | modules/core/os_snline.cpp | 2 | ||||
-rw-r--r-- | modules/core/os_sqline.cpp | 2 | ||||
-rw-r--r-- | modules/core/os_szline.cpp | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/modules/core/os_akill.cpp b/modules/core/os_akill.cpp index 6ccb33e92..a616695ce 100644 --- a/modules/core/os_akill.cpp +++ b/modules/core/os_akill.cpp @@ -195,7 +195,7 @@ class CommandOSAKill : public Command source.Reply(_("\002%s\002 added to the AKILL list."), mask.c_str()); - Log(LOG_ADMIN, u, this) << "on " << mask << " (" << reason << ") expires in " << duration(expires - Anope::CurTime) << " [affects " << affected << " user(s) (" << percent << "%)]"; + Log(LOG_ADMIN, u, this) << "on " << mask << " (" << reason << ") expires in " << (expires ? duration(expires - Anope::CurTime) : "never") << " [affects " << affected << " user(s) (" << percent << "%)]"; if (readonly) source.Reply(_(READ_ONLY_MODE)); diff --git a/modules/core/os_snline.cpp b/modules/core/os_snline.cpp index 3cb9c39fd..03ec40658 100644 --- a/modules/core/os_snline.cpp +++ b/modules/core/os_snline.cpp @@ -208,7 +208,7 @@ class CommandOSSNLine : public Command return MOD_CONT; source.Reply(_("\002%s\002 added to the SNLINE list."), mask.c_str()); - Log(LOG_ADMIN, u, this) << "on " << mask << " (" << reason << ") expires in " << duration(expires - Anope::CurTime) << " [affects " << affected << " user(s) (" << percent << "%)]"; + Log(LOG_ADMIN, u, this) << "on " << mask << " (" << reason << ") expires in " << (expires ? duration(expires - Anope::CurTime) : "never") << " [affects " << affected << " user(s) (" << percent << "%)]"; if (readonly) source.Reply(_(READ_ONLY_MODE)); diff --git a/modules/core/os_sqline.cpp b/modules/core/os_sqline.cpp index cf618107e..85c42ec4c 100644 --- a/modules/core/os_sqline.cpp +++ b/modules/core/os_sqline.cpp @@ -188,7 +188,7 @@ class CommandOSSQLine : public Command return MOD_CONT; source.Reply(_("\002%s\002 added to the SQLINE list."), mask.c_str()); - Log(LOG_ADMIN, u, this) << "on " << mask << " (" << reason << ") expires in " << duration(expires - Anope::CurTime) << " [affects " << affected << " user(s) (" << percent << "%)]"; + Log(LOG_ADMIN, u, this) << "on " << mask << " (" << reason << ") expires in " << (expires ? duration(expires - Anope::CurTime) : "never") << " [affects " << affected << " user(s) (" << percent << "%)]"; if (readonly) source.Reply(_(READ_ONLY_MODE)); diff --git a/modules/core/os_szline.cpp b/modules/core/os_szline.cpp index f57902fea..4274e94f9 100644 --- a/modules/core/os_szline.cpp +++ b/modules/core/os_szline.cpp @@ -192,7 +192,7 @@ class CommandOSSZLine : public Command return MOD_CONT; source.Reply(_("\002%s\002 added to the SZLINE list."), mask.c_str()); - Log(LOG_ADMIN, u, this) << "on " << mask << " (" << reason << ") expires in " << duration(expires - Anope::CurTime) << " [affects " << affected << " user(s) (" << percent << "%)]"; + Log(LOG_ADMIN, u, this) << "on " << mask << " (" << reason << ") expires in " << (expires ? duration(expires - Anope::CurTime) : "never") << " [affects " << affected << " user(s) (" << percent << "%)]"; if (readonly) source.Reply(_(READ_ONLY_MODE)); |