1
0
Fork 1
mirror of https://github.com/vbatts/tar-split.git synced 2024-09-27 12:44:01 +00:00
tar-split/vendor/golang.org/x/sys/unix/syscall_linux_gccgo_arm.go
Vincent Batts ec6b1ae20e
vendor the dependencies
There is a discrepancy of behavior of `github.com/urfave/cli` between
using go1.12 and go1.15, when the dependency is not present as vendored
source. Now this builds fine with go1.12

There are users of tar-split as a package. It is the hope that by adding
this vendored source it does not impact them depending on tar-split
itself.

Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
2020-10-27 12:10:40 -04:00

20 lines
589 B
Go

// Copyright 2018 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
// +build linux,gccgo,arm
package unix
import (
"syscall"
"unsafe"
)
func seek(fd int, offset int64, whence int) (int64, syscall.Errno) {
var newoffset int64
offsetLow := uint32(offset & 0xffffffff)
offsetHigh := uint32((offset >> 32) & 0xffffffff)
_, _, err := Syscall6(SYS__LLSEEK, uintptr(fd), uintptr(offsetHigh), uintptr(offsetLow), uintptr(unsafe.Pointer(&newoffset)), uintptr(whence), 0)
return newoffset, err
}