[flutter_tools] handle OsError thrown during azure detector (#64749)

This commit is contained in:
Jonah Williams
2020-08-27 17:13:04 -07:00
committed by GitHub
parent 36dc3e18ed
commit 5a4fa220e2
2 changed files with 11 additions and 0 deletions

View File

@@ -119,6 +119,9 @@ class AzureDetector {
// The HttpClient connected to a host, but it did not respond in a timely
// fashion. Assume we are not on a bot.
return _isRunningOnAzure = false;
} on OSError {
// The HttpClient might be running in a WSL1 environment.
return _isRunningOnAzure = false;
}
// We got a response. We're running on Azure.
return _isRunningOnAzure = true;