OSDN Git Service

syscall: Fix splice syscall.
authorian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 5 Dec 2012 08:48:44 +0000 (08:48 +0000)
committerian <ian@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 5 Dec 2012 08:48:44 +0000 (08:48 +0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-4_7-branch@194184 138bc75d-0d04-0410-961f-82ee72b054a4

libgo/go/syscall/libcall_linux.go

index 8d7da19..2316404 100644 (file)
@@ -310,11 +310,13 @@ func Splice(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n i
        var lroff _loff_t
        var plroff *_loff_t
        if roff != nil {
+               lroff = _loff_t(*roff)
                plroff = &lroff
        }
        var lwoff _loff_t
        var plwoff *_loff_t
        if woff != nil {
+               lwoff = _loff_t(*woff)
                plwoff = &lwoff
        }
        n, err = splice(rfd, plroff, wfd, plwoff, len, flags)