Skip to content

Commit

Permalink
Removed LOG(INFO) from cloud_print/gcp20/prototype.
Browse files Browse the repository at this point in the history
Review URL: https://codereview.chromium.org/103163006

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@239301 0039d316-1c4b-4281-b951-d872f2087c98
  • Loading branch information
vitalybuka@chromium.org committed Dec 7, 2013
1 parent 71caa9c commit 75a1ed3
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 21 deletions.
6 changes: 3 additions & 3 deletions cloud_print/gcp20/prototype/dns_sd_server.cc
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ bool DnsSdServer::Start(const ServiceParameters& serv_params, uint32 full_ttl,
full_ttl_ = full_ttl;
metadata_ = metadata;

LOG(INFO) << "DNS server started";
VLOG(0) << "DNS server started";
LOG(WARNING) << "DNS server does not support probing";

SendAnnouncement(full_ttl_);
Expand All @@ -85,7 +85,7 @@ void DnsSdServer::Shutdown() {
SendAnnouncement(0); // TTL is 0
socket_->Close();
socket_.reset(NULL);
LOG(INFO) << "DNS server stopped";
VLOG(0) << "DNS server stopped";
}

void DnsSdServer::UpdateMetadata(const std::vector<std::string>& metadata) {
Expand Down Expand Up @@ -172,7 +172,7 @@ void DnsSdServer::ProcessMessage(int len, net::IOBufferWithSize* buf) {
if (success) {
ProccessQuery(current_ttl, query, &builder);
} else { // if (success)
LOG(INFO) << "Broken package";
VLOG(0) << "Broken package";
break;
}
}
Expand Down
2 changes: 1 addition & 1 deletion cloud_print/gcp20/prototype/print_job_handler.cc
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ bool PrintJobHandler::SavePrintJob(const std::string& content,
return false;
}

LOG(INFO) << "Job saved at " << directory.value();
VLOG(0) << "Job saved at " << directory.value();
return true;
}

Expand Down
34 changes: 17 additions & 17 deletions cloud_print/gcp20/prototype/printer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -261,9 +261,9 @@ PrivetHttpServer::RegistrationErrorStatus Printer::RegistrationStart(

if (CommandLine::ForCurrentProcess()->HasSwitch("disable-confirmation")) {
state_.confirmation_state = PrinterState::CONFIRMATION_CONFIRMED;
LOG(INFO) << "Registration confirmed by default.";
VLOG(0) << "Registration confirmed by default.";
} else {
printf("%s", kUserConfirmationTitle);
LOG(WARNING) << kUserConfirmationTitle;
base::Time valid_until = base::Time::Now() +
base::TimeDelta::FromSeconds(kUserConfirmationTimeout);
base::MessageLoop::current()->PostTask(
Expand Down Expand Up @@ -517,14 +517,14 @@ void Printer::OnServerError(const std::string& description) {
void Printer::OnPrintJobsAvailable(const std::vector<Job>& jobs) {
VLOG(3) << "Function: " << __FUNCTION__;

LOG(INFO) << "Available printjobs: " << jobs.size();
VLOG(0) << "Available printjobs: " << jobs.size();
if (jobs.empty()) {
pending_print_jobs_check_ = false;
PostOnIdle();
return;
}

LOG(INFO) << "Downloading printjob.";
VLOG(0) << "Downloading printjob.";
requester_->RequestPrintJob(jobs[0]);
return;
}
Expand All @@ -546,11 +546,11 @@ void Printer::OnLocalSettingsReceived(LocalSettings::State state,
pending_local_settings_check_ = false;
switch (state) {
case LocalSettings::CURRENT:
LOG(INFO) << "No new local settings";
VLOG(0) << "No new local settings";
PostOnIdle();
break;
case LocalSettings::PENDING:
LOG(INFO) << "New local settings were received";
VLOG(0) << "New local settings were received";
ApplyLocalSettings(settings);
break;
case LocalSettings::PRINTER_DELETED:
Expand Down Expand Up @@ -710,7 +710,7 @@ void Printer::RememberAccessToken(const std::string& access_token,
kTimeToNextAccessTokenUpdate);
state_.access_token_update =
Time::Now() + TimeDelta::FromSeconds(time_to_update);
VLOG(1) << "Current access_token: " << access_token;
VLOG(0) << "Current access_token: " << access_token;
SaveToFile();
}

Expand Down Expand Up @@ -745,18 +745,18 @@ void Printer::WaitUserConfirmation(base::Time valid_until) {

if (base::Time::Now() > valid_until) {
state_.confirmation_state = PrinterState::CONFIRMATION_TIMEOUT;
LOG(INFO) << "Confirmation timeout reached.";
VLOG(0) << "Confirmation timeout reached.";
return;
}

if (_kbhit()) {
int c = _getche();
if (c == 'y' || c == 'Y') {
state_.confirmation_state = PrinterState::CONFIRMATION_CONFIRMED;
LOG(INFO) << "Registration confirmed by user.";
VLOG(0) << "Registration confirmed by user.";
} else {
state_.confirmation_state = PrinterState::CONFIRMATION_DISCARDED;
LOG(INFO) << "Registration discarded by user.";
VLOG(0) << "Registration discarded by user.";
}
return;
}
Expand Down Expand Up @@ -791,9 +791,9 @@ void Printer::SaveToFile() {
command_line_reader::ReadStatePath(kPrinterStatePathDefault));

if (printer_state::SaveToFile(file_path, state_)) {
LOG(INFO) << "Printer state written to file";
VLOG(0) << "Printer state written to file";
} else {
LOG(INFO) << "Cannot write printer state to file";
VLOG(0) << "Cannot write printer state to file";
}
}

Expand All @@ -805,15 +805,15 @@ bool Printer::LoadFromFile() {
command_line_reader::ReadStatePath(kPrinterStatePathDefault));

if (!base::PathExists(file_path)) {
LOG(INFO) << "Printer state file not found";
VLOG(0) << "Printer state file not found";
return false;
}

if (printer_state::LoadFromFile(file_path, &state_)) {
LOG(INFO) << "Printer state loaded from file";
VLOG(0) << "Printer state loaded from file";
SaveToFile();
} else {
LOG(INFO) << "Reading/parsing printer state from file failed";
VLOG(0) << "Reading/parsing printer state from file failed";
}

return true;
Expand Down Expand Up @@ -865,7 +865,7 @@ bool Printer::StartDnsServer() {
LOG(ERROR) << "No local IP found. Cannot start printer.";
return false;
}
VLOG(1) << "Local address: " << net::IPAddressToString(ip);
VLOG(0) << "Local address: " << net::IPAddressToString(ip);

uint16 port = command_line_reader::ReadHttpPort(kHttpPortDefault);

Expand Down Expand Up @@ -948,7 +948,7 @@ bool Printer::ChangeState(ConnectionState new_state) {
return false;

connection_state_ = new_state;
LOG(INFO) << base::StringPrintf(
VLOG(0) << base::StringPrintf(
"Printer is now %s (%s)",
ConnectionStateToString(connection_state_).c_str(),
IsRegistered() ? "registered" : "unregistered");
Expand Down

0 comments on commit 75a1ed3

Please sign in to comment.