Commit a3125dfb authored by Kartik Hegde's avatar Kartik Hegde Committed by Commit Bot

Update GetRandomString() in DnsLatency routine

Fix the logic to append correctly.

BUG=chromium:956783
TEST=unit_tests && ./out/Default/unit_tests
--gtest_filter=DnsLatencyRoutineTest.*

Change-Id: I08d7434c2816c696c08d6fedcdd3d522ef3a7edf
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2358598
Commit-Queue: Kartik Hegde <khegde@chromium.org>
Reviewed-by: default avatarSteven Bennetts <stevenjb@chromium.org>
Cr-Commit-Position: refs/heads/master@{#799814}
parent b7098f55
...@@ -44,7 +44,7 @@ constexpr char kHostSuffix[] = "-ccd-testing-v4.metric.gstatic.com"; ...@@ -44,7 +44,7 @@ constexpr char kHostSuffix[] = "-ccd-testing-v4.metric.gstatic.com";
const std::string GetRandomString(int length) { const std::string GetRandomString(int length) {
std::string prefix; std::string prefix;
for (int i = 0; i < length; i++) { for (int i = 0; i < length; i++) {
prefix = 'a' + base::RandInt(0, 25); prefix += ('a' + base::RandInt(0, 25));
} }
return prefix; return prefix;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment