From 74dcdf389919066ffb6b4fa00553263ab2e29784 Mon Sep 17 00:00:00 2001 From: klauspost Date: Wed, 12 Aug 2015 15:20:26 +0200 Subject: [PATCH] Add freebsd to unixes. Fix import. Fix cast. --- node_unix.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/node_unix.go b/node_unix.go index cfbe7ec61..ba4e15ed3 100644 --- a/node_unix.go +++ b/node_unix.go @@ -1,9 +1,13 @@ // -// +build dragonfly linux netbsd openbsd solaris darwin +// +build dragonfly linux netbsd openbsd freebsd solaris darwin package restic +import ( + "syscall" +) + var mknod = syscall.Mknod type statUnix syscall.Stat_t @@ -12,7 +16,7 @@ func toStatT(i interface{}) (statT, bool) { if i == nil { return nil, false } - s, ok := i.(syscall.Stat_t) + s, ok := i.(*syscall.Stat_t) if ok && s != nil { return statUnix(*s), true }