Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(367)

Unified Diff: remoting/host/host_event_logger_posix.cc

Issue 10893009: Log when the host is started for an account. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Typo on Windows code Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: remoting/host/host_event_logger_posix.cc
diff --git a/remoting/host/host_event_logger_posix.cc b/remoting/host/host_event_logger_posix.cc
index b29f9d26283fe2643eba2337028bf6b04a7ea37b..8c988e8358390ee838261165797d51a485c6354f 100644
--- a/remoting/host/host_event_logger_posix.cc
+++ b/remoting/host/host_event_logger_posix.cc
@@ -39,6 +39,9 @@ class HostEventLoggerPosix : public HostEventLogger, public HostStatusObserver {
const protocol::TransportRoute& route) OVERRIDE;
virtual void OnShutdown() OVERRIDE;
+ //HostEventLogger implementation.
alexeypa (please no reviews) 2012/08/29 15:15:48 nit: space in front of HostEventLogger
rmsousa 2012/08/29 19:24:40 Done.
+ virtual void OnStart(const std::string& xmpp_login) OVERRIDE;
+
private:
void Log(const std::string& message);
@@ -56,7 +59,6 @@ HostEventLoggerPosix::HostEventLoggerPosix(ChromotingHost* host,
application_name_(application_name) {
openlog(application_name_.c_str(), 0, LOG_USER);
host_->AddStatusObserver(this);
- Log("Started");
}
HostEventLoggerPosix::~HostEventLoggerPosix() {
@@ -91,6 +93,10 @@ void HostEventLoggerPosix::OnClientRouteChange(
void HostEventLoggerPosix::OnShutdown() {
Jamie 2012/08/29 17:24:14 Much as I dislike "while you're here" type comment
rmsousa 2012/08/29 19:24:40 I added the message, but I think Lambros's comment
Jamie 2012/08/30 06:09:33 Ah yes, I remember now. Thanks for adding it, but
rmsousa 2012/08/30 16:29:03 Done.
}
+void HostEventLoggerPosix::OnStart(const std::string& xmpp_login) {
+ Log("Host started for user: " + xmpp_login);
+}
+
void HostEventLoggerPosix::Log(const std::string& message) {
syslog(LOG_USER | LOG_NOTICE, "%s", message.c_str());
}

Powered by Google App Engine
This is Rietveld 408576698