Inlineable (*Torrent).AddPeers()
(#622)
This commit is contained in:
parent
a0fe0a087d
commit
d00ba917c0
10
t.go
10
t.go
@ -243,11 +243,11 @@ func (t *Torrent) Files() []*File {
|
|||||||
return *t.files
|
return *t.files
|
||||||
}
|
}
|
||||||
|
|
||||||
func (t *Torrent) AddPeers(pp []PeerInfo) int {
|
func (t *Torrent) AddPeers(pp []PeerInfo) (n int) {
|
||||||
cl := t.cl
|
t.cl.lock()
|
||||||
cl.lock()
|
n = t.addPeers(pp)
|
||||||
defer cl.unlock()
|
t.cl.unlock()
|
||||||
return t.addPeers(pp)
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// Marks the entire torrent for download. Requires the info first, see
|
// Marks the entire torrent for download. Requires the info first, see
|
||||||
|
Loading…
x
Reference in New Issue
Block a user