]> git.immae.eu Git - github/fretlink/terraform-provider-statuscake.git/blobdiff - vendor/github.com/hashicorp/go-getter/get_file_unix.go
Upgrade to 0.12
[github/fretlink/terraform-provider-statuscake.git] / vendor / github.com / hashicorp / go-getter / get_file_unix.go
index c89a2d5a4385df3c634fa729f9ffe9b607ef40b4..c3b28ae517a54deb814498275d5d41565ed81e86 100644 (file)
@@ -4,7 +4,6 @@ package getter
 
 import (
        "fmt"
-       "io"
        "net/url"
        "os"
        "path/filepath"
@@ -50,6 +49,7 @@ func (g *FileGetter) Get(dst string, u *url.URL) error {
 }
 
 func (g *FileGetter) GetFile(dst string, u *url.URL) error {
+       ctx := g.Context()
        path := u.Path
        if u.RawPath != "" {
                path = u.RawPath
@@ -98,6 +98,6 @@ func (g *FileGetter) GetFile(dst string, u *url.URL) error {
        }
        defer dstF.Close()
 
-       _, err = io.Copy(dstF, srcF)
+       _, err = Copy(ctx, dstF, srcF)
        return err
 }