Add finite timeout on CURL metrics endpoint.
Prevent CURL hanging up without timeout when connection can't be established. Creating a deadlock on the filesystem when executed behind a proxy.
MODIFY
src/vcpkg/metrics.cpp
src/vcpkg/metrics.cpp
@@ -483,6 +483,8 @@ namespace vcpkg::Metrics
// TODO: convert to cmd_execute_background or something.
auto curl = System::Command("curl")
.string_arg("https://dc.services.visualstudio.com/v2/track")
+ .string_arg("--max-time")
+ .string_arg("3")
.string_arg("-H")
.string_arg("Content-Type: application/json")
.string_arg("-X")

Add finite timeout on CURL metrics endpoint. (#22)

Prevent CURL hanging up without timeout when connection can't be established. Creating a deadlock on the filesystem when executed behind a proxy.