forked from TrueCloudLab/rclone
fs: make sure we don't save on the fly remote config to the config file #4996
This commit is contained in:
parent
f111e0eaf8
commit
3dbef2b2fd
1 changed files with 3 additions and 0 deletions
3
fs/fs.go
3
fs/fs.go
|
@ -1282,6 +1282,9 @@ type setConfigFile string
|
||||||
|
|
||||||
// Set a config item into the config file
|
// Set a config item into the config file
|
||||||
func (section setConfigFile) Set(key, value string) {
|
func (section setConfigFile) Set(key, value string) {
|
||||||
|
if strings.HasPrefix(string(section), ":") {
|
||||||
|
Errorf(nil, "Can't save config %q = %q for on the fly backend %q", key, value, section)
|
||||||
|
}
|
||||||
Debugf(nil, "Saving config %q = %q in section %q of the config file", key, value, section)
|
Debugf(nil, "Saving config %q = %q in section %q of the config file", key, value, section)
|
||||||
err := ConfigFileSet(string(section), key, value)
|
err := ConfigFileSet(string(section), key, value)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Add table
Reference in a new issue