From 072464cbdbb4c759b417acb4c29d266141af593b Mon Sep 17 00:00:00 2001 From: Nick Craig-Wood Date: Tue, 19 Jan 2021 15:10:35 +0000 Subject: [PATCH] gcs: fix anonymous client to use rclone's HTTP client --- backend/googlecloudstorage/googlecloudstorage.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/googlecloudstorage/googlecloudstorage.go b/backend/googlecloudstorage/googlecloudstorage.go index afa2c7ce9..0eba5f54f 100644 --- a/backend/googlecloudstorage/googlecloudstorage.go +++ b/backend/googlecloudstorage/googlecloudstorage.go @@ -411,7 +411,7 @@ func NewFs(ctx context.Context, name, root string, m configmap.Mapper) (fs.Fs, e opt.ServiceAccountCredentials = string(loadedCreds) } if opt.Anonymous { - oAuthClient = &http.Client{} + oAuthClient = fshttp.NewClient(ctx) } else if opt.ServiceAccountCredentials != "" { oAuthClient, err = getServiceAccountClient(ctx, []byte(opt.ServiceAccountCredentials)) if err != nil {