From 8ae037c8a1c2fcb99c5b38362a6e4c65aabd4aa1 Mon Sep 17 00:00:00 2001 From: Sergey Kozlov Date: Tue, 8 Feb 2022 21:03:48 +0000 Subject: [PATCH] Fix typing issues in createTimeWithContext on Freebsd/i386 Before change: ``` $ GOOS=freebsd GOARCH=386 go build ./process process\process_freebsd.go:118:26: cannot use k.Start.Sec * 1000 + k.Start.Usec / 1000 (type int32) as type int64 in return argument ``` --- process/process_freebsd.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/process/process_freebsd.go b/process/process_freebsd.go index 444af35..183354e 100644 --- a/process/process_freebsd.go +++ b/process/process_freebsd.go @@ -115,7 +115,7 @@ func (p *Process) createTimeWithContext(ctx context.Context) (int64, error) { if err != nil { return 0, err } - return k.Start.Sec*1000 + k.Start.Usec/1000, nil + return int64(k.Start.Sec)*1000 + int64(k.Start.Usec)/1000, nil } func (p *Process) StatusWithContext(ctx context.Context) ([]string, error) {