Skip to content

Commit

Permalink
Merge pull request #742 from google/protect-vlog
Browse files Browse the repository at this point in the history
protect VLOG by use_logging
  • Loading branch information
sergiud authored Nov 18, 2021
2 parents b79e18b + 65199ed commit 11f08e7
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/logging.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2167,7 +2167,9 @@ static bool SendEmailInternal(const char*dest, const char *subject,
string cmd =
logmailer + " -s" +
ShellEscape(subject) + " " + ShellEscape(dest);
VLOG(4) << "Mailing command: " << cmd;
if (use_logging) {
VLOG(4) << "Mailing command: " << cmd;
}

FILE* pipe = popen(cmd.c_str(), "w");
if (pipe != NULL) {
Expand Down

0 comments on commit 11f08e7

Please sign in to comment.