NetEQ RTP play: textlog to stderr as option

Bug: webrtc:10548
Change-Id: I260b6c63621c61e33fcc38fd0a39cfb0dba3bc20
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/160413
Reviewed-by: Henrik Lundin <henrik.lundin@webrtc.org>
Commit-Queue: Alessio Bazzica <alessiob@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#29915}
This commit is contained in:
Alessio Bazzica
2019-11-25 16:35:12 +01:00
committed by Commit Bot
parent 27bd76bcb2
commit a88655daf9
3 changed files with 15 additions and 7 deletions

View File

@ -247,11 +247,11 @@ bool ValidateOutputFilesOptions(bool textlog,
return false;
}
// Without |output_audio_filename|, |output_files_base_name| is required when
// one or more output files must be generated (in order to form a valid output
// plotting output files must be generated (in order to form a valid output
// file name).
if (output_audio_filename.empty() && (textlog || plotting) &&
if (output_audio_filename.empty() && plotting &&
!output_files_base_name_specified) {
std::cout << "Error: when no output audio file is specified and --textlog, "
std::cout << "Error: when no output audio file is specified and "
<< "--matlabplot and/or --pythonplot are used, "
<< "--output_files_base_name must be also used." << std::endl;
return false;
@ -378,6 +378,7 @@ int main(int argc, char* argv[]) {
if (!output_audio_filename.empty()) {
config.output_audio_filename = output_audio_filename;
}
config.textlog = absl::GetFlag(FLAGS_textlog);
config.textlog_filename = CreateOptionalOutputFileName(
absl::GetFlag(FLAGS_textlog), output_files_base_name,
output_audio_filename, ".text_log.txt");