Use flag name without 'no' prefix only if it exists
Before this change it was impossible to use flag names that start with "no", e.g. --noise_file
BUG=webrtc:8202
Review-Url: https://codereview.webrtc.org/3004363002
Cr-Commit-Position: refs/heads/master@{#19678}
diff --git a/webrtc/rtc_base/flags.cc b/webrtc/rtc_base/flags.cc
index a245cec..b5697f1 100644
--- a/webrtc/rtc_base/flags.cc
+++ b/webrtc/rtc_base/flags.cc
@@ -149,7 +149,7 @@
arg++; // remove 1st '-'
if (*arg == '-')
arg++; // remove 2nd '-'
- if (arg[0] == 'n' && arg[1] == 'o') {
+ if (arg[0] == 'n' && arg[1] == 'o' && Lookup(arg + 2)) {
arg += 2; // remove "no"
*is_bool = true;
}