mirror of
https://github.com/rclone/rclone.git
synced 2024-11-29 03:48:27 +08:00
serve dnla: fix crash on graceful exit
Before this change, closing a uninitialised chan would cause a crash.
This commit is contained in:
parent
23ab6fa3a0
commit
4ab57eb90b
|
@ -129,11 +129,10 @@ func newServer(f fs.Fs, opt *dlnaflags.Options) (*server, error) {
|
||||||
FriendlyName: friendlyName,
|
FriendlyName: friendlyName,
|
||||||
RootDeviceUUID: makeDeviceUUID(friendlyName),
|
RootDeviceUUID: makeDeviceUUID(friendlyName),
|
||||||
Interfaces: interfaces,
|
Interfaces: interfaces,
|
||||||
|
waitChan: make(chan struct{}),
|
||||||
httpListenAddr: opt.ListenAddr,
|
httpListenAddr: opt.ListenAddr,
|
||||||
|
f: f,
|
||||||
f: f,
|
vfs: vfs.New(f, &vfsflags.Opt),
|
||||||
vfs: vfs.New(f, &vfsflags.Opt),
|
|
||||||
}
|
}
|
||||||
|
|
||||||
s.services = map[string]UPnPService{
|
s.services = map[string]UPnPService{
|
||||||
|
|
Loading…
Reference in New Issue
Block a user