From: Matt Joiner Date: Mon, 12 May 2025 02:20:15 +0000 (+1000) Subject: Add comment on gotMetainfoC X-Git-Tag: v1.59.0~159 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=f569b2c1a76808b987175f8dec286b1dd7e94b9d;p=btrtrc.git Add comment on gotMetainfoC --- diff --git a/torrent.go b/torrent.go index 5e02c807..e780c80f 100644 --- a/torrent.go +++ b/torrent.go @@ -148,7 +148,8 @@ type Torrent struct { metadataCompletedChunks []bool metadataChanged sync.Cond - // Closed when .Info is obtained. + // Closed when .Info is obtained. This could be chansync.SetOnce but we already have sync around + // IsSet from nameMu. Switching will probably only increase memory use. gotMetainfoC chan struct{} readers map[*reader]struct{}