mirror of https://github.com/hashicorp/terraform
The p.ConfigureProviderCalled read needs to be guarded by the mutex so that it can't race with the write to that field in the ConfigureProvider method. This remains as a pair of explicit calls to Unlock rather than as a single deferred call because existing tests might be relying on their ApplyResourceChangeFn being called without the mutex locked. This isn't necessarily required, but I'm being conservative to reduce the risk of unexpectedly making subtle changes to the behavior of existing tests.pull/34738/head
parent
532bc60d34
commit
4fb8a1cdb7
Loading…
Reference in new issue