Compare commits

...
4 Commits
Author SHA1 Message Date
Nick Craig-Wood 373fb01725 Version v1.50.2 2019-11-19 16:03:01 +00:00
Nick Craig-Wood 7766c5c90b accounting: fix memory leak on retries operations
Before this change if an operation was retried on operations.Copy and
the operation was large enough to use an async buffer then an async
buffer was leaked on the retry.  This leaked memory, a file handle and
a go routine.

After this change if Account.WithBuffer is called and there is already
a buffer, then a new one won't be allocated.
2019-11-19 12:12:47 +00:00
Nick Craig-Wood 473a437163 drive: fix --drive-root-folder-id with team/shared drives
Before this change rclone used the team_drive ID as the root if set
even if the root_folder_id was set too.

This change uses the root_folder_id in preference over the team_drive
which restores the functionality.

This problem was introduced by ba7c2ac443

Fixes #3742
2019-11-17 14:50:44 +00:00
Nick Craig-Wood 9662554f53 drive: fix listing of the root directory with drive.files scope
We attempt to find the ID of the root folder by doing a GET on the
folder ID "root". With scope "drive.files" this fails with a 404
message.

After this change if we get the 404 message, we just carry on using
"root" as the root folder ID and we cache that for future lookups.

This means that changenotify messages will not work correctly in the
root folder but otherwise has minor consequences.

See: https://forum.rclone.org/t/fresh-raspberry-pi-build-google-drive-404-error-failed-to-ls-googleapi-error-404-file-not-found/12791
2019-11-11 09:07:54 +00:00
79 changed files with 157 additions and 88 deletions

No files matched your search

Generated
+14 -2
View File
@@ -17,7 +17,7 @@
<header id="title-block-header">
<h1 class="title">rclone(1) User Manual</h1>
<p class="author">Nick Craig-Wood</p>
<p class="date">Nov 02, 2019</p>
<p class="date">Nov 19, 2019</p>
</header>
<h1 id="rclone---rsync-for-cloud-storage">Rclone - rsync for cloud storage</h1>
<p>Rclone is a command line program to sync files and directories to and from:</p>
@@ -4963,7 +4963,7 @@ Showing nodes accounting for 1537.03kB, 100% of 1537.03kB total
--use-json-log Use json log format.
--use-mmap Use mmap allocator (see docs).
--use-server-modtime Use server modified time instead of object metadata
--user-agent string Set the user-agent to a specified string. The default is rclone/ version (default &quot;rclone/v1.50.1&quot;)
--user-agent string Set the user-agent to a specified string. The default is rclone/ version (default &quot;rclone/v1.50.2&quot;)
-v, --verbose count Print lots more stuff (repeat for more)</code></pre>
<h2 id="backend-flags">Backend Flags</h2>
<p>These flags are available for every command. They control the backends and may be set in the config file.</p>
@@ -14535,6 +14535,18 @@ $ tree /tmp/b
</ul>
<!--- autogenerated options stop -->
<h1 id="changelog">Changelog</h1>
<h2 id="v1.50.2---2019-11-19">v1.50.2 - 2019-11-19</h2>
<ul>
<li>Bug Fixes
<ul>
<li>accounting: Fix memory leak on retries operations (Nick Craig-Wood)</li>
</ul></li>
<li>Drive
<ul>
<li>Fix listing of the root directory with drive.files scope (Nick Craig-Wood)</li>
<li>Fix –drive-root-folder-id with team/shared drives (Nick Craig-Wood)</li>
</ul></li>
</ul>
<h2 id="v1.50.1---2019-11-02">v1.50.1 - 2019-11-02</h2>
<ul>
<li>Bug Fixes
Generated
+10 -2
View File
@@ -1,6 +1,6 @@
% rclone(1) User Manual
% Nick Craig-Wood
% Nov 02, 2019
% Nov 19, 2019
# Rclone - rsync for cloud storage
@@ -8460,7 +8460,7 @@ These flags are available for every command.
--use-json-log Use json log format.
--use-mmap Use mmap allocator (see docs).
--use-server-modtime Use server modified time instead of object metadata
--user-agent string Set the user-agent to a specified string. The default is rclone/ version (default "rclone/v1.50.1")
--user-agent string Set the user-agent to a specified string. The default is rclone/ version (default "rclone/v1.50.2")
-v, --verbose count Print lots more stuff (repeat for more)
```
@@ -20189,6 +20189,14 @@ to override the default choice.
# Changelog
## v1.50.2 - 2019-11-19
* Bug Fixes
* accounting: Fix memory leak on retries operations (Nick Craig-Wood)
* Drive
* Fix listing of the root directory with drive.files scope (Nick Craig-Wood)
* Fix --drive-root-folder-id with team/shared drives (Nick Craig-Wood)
## v1.50.1 - 2019-11-02
* Bug Fixes
Generated
+14 -2
View File
@@ -1,6 +1,6 @@
rclone(1) User Manual
Nick Craig-Wood
Nov 02, 2019
Nov 19, 2019
@@ -8067,7 +8067,7 @@ These flags are available for every command.
--use-json-log Use json log format.
--use-mmap Use mmap allocator (see docs).
--use-server-modtime Use server modified time instead of object metadata
--user-agent string Set the user-agent to a specified string. The default is rclone/ version (default "rclone/v1.50.1")
--user-agent string Set the user-agent to a specified string. The default is rclone/ version (default "rclone/v1.50.2")
-v, --verbose count Print lots more stuff (repeat for more)
@@ -19668,6 +19668,18 @@ override the default choice.
CHANGELOG
v1.50.2 - 2019-11-19
- Bug Fixes
- accounting: Fix memory leak on retries operations (Nick
Craig-Wood)
- Drive
- Fix listing of the root directory with drive.files scope (Nick
Craig-Wood)
- Fix –drive-root-folder-id with team/shared drives (Nick
Craig-Wood)
v1.50.1 - 2019-11-02
- Bug Fixes
+1 -1
View File
@@ -1 +1 @@
v1.50.1
v1.50.2
+10 -4
View File
@@ -1021,16 +1021,22 @@ func NewFs(name, path string, m configmap.Mapper) (fs.Fs, error) {
}
// set root folder for a team drive or query the user root folder
if f.isTeamDrive {
f.rootFolderID = f.opt.TeamDriveID
} else if opt.RootFolderID != "" {
if opt.RootFolderID != "" {
// override root folder if set or cached in the config
f.rootFolderID = opt.RootFolderID
} else if f.isTeamDrive {
f.rootFolderID = f.opt.TeamDriveID
} else {
// Look up the root ID and cache it in the config
rootID, err := f.getRootID()
if err != nil {
return nil, err
if gerr, ok := errors.Cause(err).(*googleapi.Error); ok && gerr.Code == 404 {
// 404 means that this scope does not have permission to get the
// root so just use "root"
rootID = "root"
} else {
return nil, err
}
}
f.rootFolderID = rootID
m.Set("root_folder_id", rootID)
+9 -1
View File
@@ -1,11 +1,19 @@
---
title: "Documentation"
description: "Rclone Changelog"
date: "2019-11-02"
date: "2019-11-19"
---
# Changelog
## v1.50.2 - 2019-11-19
* Bug Fixes
* accounting: Fix memory leak on retries operations (Nick Craig-Wood)
* Drive
* Fix listing of the root directory with drive.files scope (Nick Craig-Wood)
* Fix --drive-root-folder-id with team/shared drives (Nick Craig-Wood)
## v1.50.1 - 2019-11-02
* Bug Fixes
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone"
slug: rclone
url: /commands/rclone/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone about"
slug: rclone_about
url: /commands/rclone_about/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone authorize"
slug: rclone_authorize
url: /commands/rclone_authorize/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone cachestats"
slug: rclone_cachestats
url: /commands/rclone_cachestats/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone cat"
slug: rclone_cat
url: /commands/rclone_cat/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone check"
slug: rclone_check
url: /commands/rclone_check/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone cleanup"
slug: rclone_cleanup
url: /commands/rclone_cleanup/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config"
slug: rclone_config
url: /commands/rclone_config/
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config create"
slug: rclone_config_create
url: /commands/rclone_config_create/
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config delete"
slug: rclone_config_delete
url: /commands/rclone_config_delete/
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config disconnect"
slug: rclone_config_disconnect
url: /commands/rclone_config_disconnect/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config dump"
slug: rclone_config_dump
url: /commands/rclone_config_dump/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config edit"
slug: rclone_config_edit
url: /commands/rclone_config_edit/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config file"
slug: rclone_config_file
url: /commands/rclone_config_file/
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config password"
slug: rclone_config_password
url: /commands/rclone_config_password/
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config providers"
slug: rclone_config_providers
url: /commands/rclone_config_providers/
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config reconnect"
slug: rclone_config_reconnect
url: /commands/rclone_config_reconnect/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config show"
slug: rclone_config_show
url: /commands/rclone_config_show/
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config update"
slug: rclone_config_update
url: /commands/rclone_config_update/
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone config userinfo"
slug: rclone_config_userinfo
url: /commands/rclone_config_userinfo/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone copy"
slug: rclone_copy
url: /commands/rclone_copy/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone copyto"
slug: rclone_copyto
url: /commands/rclone_copyto/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone copyurl"
slug: rclone_copyurl
url: /commands/rclone_copyurl/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone cryptcheck"
slug: rclone_cryptcheck
url: /commands/rclone_cryptcheck/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone cryptdecode"
slug: rclone_cryptdecode
url: /commands/rclone_cryptdecode/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone dbhashsum"
slug: rclone_dbhashsum
url: /commands/rclone_dbhashsum/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone dedupe"
slug: rclone_dedupe
url: /commands/rclone_dedupe/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone delete"
slug: rclone_delete
url: /commands/rclone_delete/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone deletefile"
slug: rclone_deletefile
url: /commands/rclone_deletefile/
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone genautocomplete"
slug: rclone_genautocomplete
url: /commands/rclone_genautocomplete/
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone genautocomplete bash"
slug: rclone_genautocomplete_bash
url: /commands/rclone_genautocomplete_bash/
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone genautocomplete zsh"
slug: rclone_genautocomplete_zsh
url: /commands/rclone_genautocomplete_zsh/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone gendocs"
slug: rclone_gendocs
url: /commands/rclone_gendocs/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone hashsum"
slug: rclone_hashsum
url: /commands/rclone_hashsum/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone link"
slug: rclone_link
url: /commands/rclone_link/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone listremotes"
slug: rclone_listremotes
url: /commands/rclone_listremotes/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone ls"
slug: rclone_ls
url: /commands/rclone_ls/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone lsd"
slug: rclone_lsd
url: /commands/rclone_lsd/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone lsf"
slug: rclone_lsf
url: /commands/rclone_lsf/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone lsjson"
slug: rclone_lsjson
url: /commands/rclone_lsjson/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone lsl"
slug: rclone_lsl
url: /commands/rclone_lsl/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone md5sum"
slug: rclone_md5sum
url: /commands/rclone_md5sum/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone mkdir"
slug: rclone_mkdir
url: /commands/rclone_mkdir/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone mount"
slug: rclone_mount
url: /commands/rclone_mount/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone move"
slug: rclone_move
url: /commands/rclone_move/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone moveto"
slug: rclone_moveto
url: /commands/rclone_moveto/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone ncdu"
slug: rclone_ncdu
url: /commands/rclone_ncdu/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone obscure"
slug: rclone_obscure
url: /commands/rclone_obscure/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone purge"
slug: rclone_purge
url: /commands/rclone_purge/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone rc"
slug: rclone_rc
url: /commands/rclone_rc/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone rcat"
slug: rclone_rcat
url: /commands/rclone_rcat/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone rcd"
slug: rclone_rcd
url: /commands/rclone_rcd/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone rmdir"
slug: rclone_rmdir
url: /commands/rclone_rmdir/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone rmdirs"
slug: rclone_rmdirs
url: /commands/rclone_rmdirs/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone serve"
slug: rclone_serve
url: /commands/rclone_serve/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone serve dlna"
slug: rclone_serve_dlna
url: /commands/rclone_serve_dlna/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone serve ftp"
slug: rclone_serve_ftp
url: /commands/rclone_serve_ftp/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone serve http"
slug: rclone_serve_http
url: /commands/rclone_serve_http/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone serve restic"
slug: rclone_serve_restic
url: /commands/rclone_serve_restic/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone serve sftp"
slug: rclone_serve_sftp
url: /commands/rclone_serve_sftp/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone serve webdav"
slug: rclone_serve_webdav
url: /commands/rclone_serve_webdav/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone settier"
slug: rclone_settier
url: /commands/rclone_settier/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone sha1sum"
slug: rclone_sha1sum
url: /commands/rclone_sha1sum/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone size"
slug: rclone_size
url: /commands/rclone_size/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone sync"
slug: rclone_sync
url: /commands/rclone_sync/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone touch"
slug: rclone_touch
url: /commands/rclone_touch/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone tree"
slug: rclone_tree
url: /commands/rclone_tree/
+1 -1
View File
@@ -1,5 +1,5 @@
---
date: 2019-11-02T14:26:08Z
date: 2019-11-19T16:02:36Z
title: "rclone version"
slug: rclone_version
url: /commands/rclone_version/
+2 -2
View File
@@ -1,7 +1,7 @@
---
title: "Global Flags"
description: "Rclone Global Flags"
date: "2019-11-02T14:26:08Z"
date: "2019-11-19T16:02:36Z"
---
# Global Flags
@@ -127,7 +127,7 @@ These flags are available for every command.
--use-json-log Use json log format.
--use-mmap Use mmap allocator (see docs).
--use-server-modtime Use server modified time instead of object metadata
--user-agent string Set the user-agent to a specified string. The default is rclone/ version (default "rclone/v1.50.1")
--user-agent string Set the user-agent to a specified string. The default is rclone/ version (default "rclone/v1.50.2")
-v, --verbose count Print lots more stuff (repeat for more)
```
+1 -1
View File
@@ -1 +1 @@
v1.50.1
v1.50.2
+8 -2
View File
@@ -70,6 +70,10 @@ func newAccountSizeName(stats *StatsInfo, in io.ReadCloser, size int64, name str
// WithBuffer - If the file is above a certain size it adds an Async reader
func (acc *Account) WithBuffer() *Account {
// if already have a buffer then just return
if acc.withBuf {
return acc
}
acc.withBuf = true
var buffers int
if acc.size >= int64(fs.Config.BufferSize) || acc.size == -1 {
@@ -118,14 +122,16 @@ func (acc *Account) StopBuffering() {
// async buffer (if any) and re-adding it
func (acc *Account) UpdateReader(in io.ReadCloser) {
acc.mu.Lock()
if acc.withBuf {
withBuf := acc.withBuf
if withBuf {
acc.StopBuffering()
acc.withBuf = false
}
acc.in = in
acc.close = in
acc.origIn = in
acc.closed = false
if acc.withBuf {
if withBuf {
acc.WithBuffer()
}
acc.mu.Unlock()
+1 -1
View File
@@ -1,4 +1,4 @@
package fs
// Version of rclone
var Version = "v1.50.1"
var Version = "v1.50.2"
Generated
+19 -2
View File
@@ -1,7 +1,7 @@
.\"t
.\" Automatically generated by Pandoc 2.5
.\"
.TH "rclone" "1" "Nov 02, 2019" "User Manual" ""
.TH "rclone" "1" "Nov 19, 2019" "User Manual" ""
.hy
.SH Rclone \- rsync for cloud storage
.PP
@@ -11054,7 +11054,7 @@ These flags are available for every command.
\-\-use\-json\-log Use json log format.
\-\-use\-mmap Use mmap allocator (see docs).
\-\-use\-server\-modtime Use server modified time instead of object metadata
\-\-user\-agent string Set the user\-agent to a specified string. The default is rclone/ version (default \[dq]rclone/v1.50.1\[dq])
\-\-user\-agent string Set the user\-agent to a specified string. The default is rclone/ version (default \[dq]rclone/v1.50.2\[dq])
\-v, \-\-verbose count Print lots more stuff (repeat for more)
\f[R]
.fi
@@ -27232,6 +27232,23 @@ Type: bool
.IP \[bu] 2
Default: false
.SH Changelog
.SS v1.50.2 \- 2019\-11\-19
.IP \[bu] 2
Bug Fixes
.RS 2
.IP \[bu] 2
accounting: Fix memory leak on retries operations (Nick Craig\-Wood)
.RE
.IP \[bu] 2
Drive
.RS 2
.IP \[bu] 2
Fix listing of the root directory with drive.files scope (Nick
Craig\-Wood)
.IP \[bu] 2
Fix \[en]drive\-root\-folder\-id with team/shared drives (Nick
Craig\-Wood)
.RE
.SS v1.50.1 \- 2019\-11\-02
.IP \[bu] 2
Bug Fixes