influxdb/pkg
Ayan George bd47d8efe1
fix: Type-convert fs.Bavail for portability (#19816)
Prior to this patch, DiskUsage() would calculate bytes available
by multiplying blocks available by block size in bytes:

  disk.Avail = fs.Bavail * uint64(fs.Bsize)

Under some versions of Unix, fs.Bavail is of type uint64 and on
others (like FreeBSD) it is of type int64.

This causes a compile time error:

  $ go build
  # github.com/influxdata/influxdb/v2/pkg/fs
  ./fs_unix.go:81:25: invalid operation: fs.Bavail * uint64(fs.Bsize) (mismatched types int64 and uint64)

This patch type-converts fs.Bavail to unit64 to ensure that all
types in the expression align.

This prevents compile time errors under FreeBSD and other platforms
where fs.Bavail isn't uint64.
2020-10-26 05:32:04 -04:00
..
binaryutil Initial import pkg package 2018-10-01 12:03:20 +01:00
bloom chore: Skip tests on circleci 2020-08-31 12:14:27 -07:00
bufio feat: buffered io.WriteCloser 2020-03-13 11:00:28 +00:00
bytesutil refactor: rewrite imports to include the /v2 suffix for version 2 2020-04-03 12:39:20 -05:00
csv2lp fix: Panic when p is < what was read from rd 2020-09-29 13:44:18 -07:00
data/gen chore: move v2/v1/tsdb → v2/tsdb 2020-08-26 10:46:47 -07:00
deep chore(tsdb): Initial commit of tsdb package 2020-08-03 09:17:23 -07:00
encoding/simple8b fix: typos (#19734) 2020-10-13 09:50:32 -07:00
escape chore(tsdb): Initial commit of tsdb package 2020-08-03 09:17:23 -07:00
estimator chore(tsdb): Initial commit of tsdb package 2020-08-03 09:17:23 -07:00
file chore(tsdb): Initial commit of tsdb package 2020-08-03 09:17:23 -07:00
fs fix: Type-convert fs.Bavail for portability (#19816) 2020-10-26 05:32:04 -04:00
hll refactor(hll): remove unused Sketch interface (#17218) 2020-03-12 08:59:05 -07:00
httpc feat(httpc): add error return argument to auth func (#19085) 2020-07-28 14:59:01 +01:00
jsonnet refactor: rewrite imports to include the /v2 suffix for version 2 2020-04-03 12:39:20 -05:00
jsonparser refactor: rewrite imports to include the /v2 suffix for version 2 2020-04-03 12:39:20 -05:00
lifecycle tsi1: partition close deadlock 2019-04-22 09:06:32 -06:00
limiter refactor: rewrite imports to include the /v2 suffix for version 2 2020-04-03 12:39:20 -05:00
metrics chore: update staticcheck and fix newly identified lint checks (#18737) 2020-06-26 18:54:09 -05:00
mincore feat(tsi1): Add optional mincore limiter to TSI 2020-07-22 10:17:42 -06:00
mmap refactor: rewrite imports to include the /v2 suffix for version 2 2020-04-03 12:39:20 -05:00
pointer Fix typos in miscellaneous packages 2019-04-17 13:30:22 -07:00
pool fix: typos (#19734) 2020-10-13 09:50:32 -07:00
radix chore(tsdb): Initial commit of tsdb package 2020-08-03 09:17:23 -07:00
rhh refactor: rewrite imports to include the /v2 suffix for version 2 2020-04-03 12:39:20 -05:00
slices chore(tsdb): Initial commit of tsdb package 2020-08-03 09:17:23 -07:00
snowflake Initial import pkg package 2018-10-01 12:03:20 +01:00
tar chore(tsdb): Initial commit of tsdb package 2020-08-03 09:17:23 -07:00
testing/assert chore(gen): Add ingen generator data structures to platform for reuse 2018-12-11 17:45:57 -07:00
testttp chore(testtp): extend testtp request with SetFormValue 2020-04-16 14:39:07 -07:00
tracing chore(tsdb): Initial commit of tsdb package 2020-08-03 09:17:23 -07:00