From 41e2595443d376da01233445687bd890a3a2bcb6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ville=20Skytt=C3=A4?= Date: Wed, 5 Jan 2022 01:20:20 +0200 Subject: [PATCH] [process][freebsd] implement createTimeWithContext --- process/process_freebsd.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/process/process_freebsd.go b/process/process_freebsd.go index a010383..383ec0f 100644 --- a/process/process_freebsd.go +++ b/process/process_freebsd.go @@ -111,7 +111,11 @@ func (p *Process) CmdlineSliceWithContext(ctx context.Context) ([]string, error) } func (p *Process) createTimeWithContext(ctx context.Context) (int64, error) { - return 0, common.ErrNotImplementedError + k, err := p.getKProc() + if err != nil { + return 0, err + } + return k.Start.Sec*1000 + k.Start.Usec/1000, nil } func (p *Process) ParentWithContext(ctx context.Context) (*Process, error) {