[url] Harden StringPieceReplacements API

This change hardens the StringPieceReplacements API for URLs by
disallowing passing rvalue references to std::string. Passing these
references is unsafe, since the StringPieceReplacements don't take
ownership of the string, and expect it to remain valid during its
lifetime.

Bug: None
Change-Id: I85480553fa4bd2fe177c51fd1868c40888d88913
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2288568
Commit-Queue: Jan Wilken Dörrie <jdoerrie@chromium.org>
Commit-Queue: Rohit Rao <rohitrao@chromium.org>
Reviewed-by: Rohit Rao <rohitrao@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Auto-Submit: Jan Wilken Dörrie <jdoerrie@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#787214}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: c00e27b4a5da5e8d10609e849ad6e97d072625e8
1 file changed