mirror of
https://github.com/rclone/rclone.git
synced 2025-12-22 11:13:23 +00:00
oauthutil: Added AuthOptions and shuts down the web server properly
1. This makes AuthOptions a parameter for doConfig, Config and ConfigOffline to enable a Fs to add additional options (required for OneDrive for Business) 2. Fix to properly shutdown the webserver recieving the auth information (go1.8)
This commit is contained in:
committed by
Nick Craig-Wood
parent
6d59887487
commit
73f7278497
16
oauthutil/oauthutil_old.go
Normal file
16
oauthutil/oauthutil_old.go
Normal file
@@ -0,0 +1,16 @@
|
||||
// oauthutil parts pre go1.8+
|
||||
|
||||
//+build !go1.8
|
||||
|
||||
package oauthutil
|
||||
|
||||
import "github.com/ncw/rclone/fs"
|
||||
|
||||
func (s *authServer) Stop() {
|
||||
fs.Debugf(nil, "Closing auth server")
|
||||
if s.code != nil {
|
||||
close(s.code)
|
||||
s.code = nil
|
||||
}
|
||||
_ = s.listener.Close()
|
||||
}
|
||||
Reference in New Issue
Block a user