Save the latest alt service info for the same canonical suffixes.

HttpServerPropertiesManager::WriteToPrefs() saves only one alt service
info for the same canonical suffixes. This is intended to reduce disk
consumption. But currently it is saving the oldest alt service info.
This is strange because HttpServerProperties prefers canonical entry
hits that are more recently learned. So this CL changes the method to
save the latest alt service info for canonical suffix.

Bug: 994842
Change-Id: I7b788ff308a9a208e04b08d1882b0467efdc1e18
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3731727
Reviewed-by: Yutaka Hirano <yhirano@chromium.org>
Commit-Queue: Tsuyoshi Horo <horo@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1020479}
NOKEYCHECK=True
GitOrigin-RevId: d9e3f026a344432c74a7aceec7c98b7f4b92adce
2 files changed