utils

package
v0.0.0-...-db95cbe Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 13, 2020 License: GPL-3.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

View Source
const (
	KB
	MB
	GB
	TB
	PB
	EB
)

Variables

This section is empty.

Functions

func CleanFName

func CleanFName(file string) string

func Format

func Format(b float64) string

func FreeOSMem

func FreeOSMem()

func FreeOSMemGC

func FreeOSMemGC()

func GetDefTrackers

func GetDefTrackers() []string

func GetReadahead

func GetReadahead() int64

func GotInfo

func GotInfo(t *torrent.Torrent, timeout int) error

func Limit

func Limit(i int) *rate.Limiter

func ParallelFor

func ParallelFor(begin, end int, fn func(i int))

func PeerIDRandom

func PeerIDRandom(peer string) string

func ReadBlockedIP

func ReadBlockedIP() (ranger iplist.Ranger, err error)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL