cmd/go: extract module zip files in place
Previously, we extracted module zip files to temporary directories with random names, then renamed them to their final locations. This failed with ERROR_ACCESS_DENIED on Windows if any file in the temporary was open. Antivirus programs did this occasionally. Retrying the rename did not work (CL 220978). With this change, we extract module zip files in place. We create a .partial file alongside the .lock file to indicate a directory is not fully populated, and we delete this at the end of the process. Updates #36568 Change-Id: I75c09df879a602841f3459322c021896292b2fdb Reviewed-on: https://go-review.googlesource.com/c/go/+/221157 Run-TryBot: Jay Conrod <jayconrod@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by:Bryan C. Mills <bcmills@google.com> Reviewed-by:
Michael Matloob <matloob@golang.org>
Loading
Please sign in to comment