Skip to content

Commit 42049c5

Browse files
committed
unix: go fmt
1 parent 1809462 commit 42049c5

File tree

3 files changed

+8
-9
lines changed

3 files changed

+8
-9
lines changed

unix/mmap_zos_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -75,11 +75,11 @@ func TestMmap(t *testing.T) {
7575

7676
func TestMmapPtr(t *testing.T) {
7777
p, err := unix.MmapPtr(-1, 0, nil, uintptr(2*unix.Getpagesize()),
78-
unix.PROT_READ | unix.PROT_WRITE, unix.MAP_ANON|unix.MAP_PRIVATE)
78+
unix.PROT_READ|unix.PROT_WRITE, unix.MAP_ANON|unix.MAP_PRIVATE)
7979
if err != nil {
8080
t.Fatalf("MmapPtr: %v", err)
8181
}
82-
82+
8383
*(*byte)(p) = 42
8484

8585
if err := unix.MunmapPtr(p, uintptr(2*unix.Getpagesize())); err != nil {

unix/syscall_zos_s390x.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -777,7 +777,6 @@ func MunmapPtr(addr unsafe.Pointer, length uintptr) (err error) {
777777
return mapper.munmap(uintptr(addr), length)
778778
}
779779

780-
781780
//sys Gethostname(buf []byte) (err error) = SYS___GETHOSTNAME_A
782781
//sysnb Getgid() (gid int)
783782
//sysnb Getpid() (pid int)
@@ -3142,7 +3141,7 @@ func Fcntl(fd uintptr, cmd int, op interface{}) (ret int, err error) {
31423141
case *Flock_t:
31433142
err = FcntlFlock(fd, cmd, op.(*Flock_t))
31443143
if err != nil {
3145-
ret = -1
3144+
ret = -1
31463145
}
31473146
return
31483147
case int:
@@ -3183,10 +3182,10 @@ func sendfile(outfd int, infd int, offset *int64, count int) (written int, err e
31833182
var n int = 0
31843183
for i := 0; i < count; i += n {
31853184
n, err := Read(infd, buf)
3186-
if n == 0 {
3185+
if n == 0 {
31873186
if err != nil {
31883187
return -1, err
3189-
} else { // EOF
3188+
} else { // EOF
31903189
break
31913190
}
31923191
}

unix/ztypes_zos_s390x.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -378,9 +378,9 @@ type Flock_t struct {
378378
}
379379

380380
type F_cnvrt struct {
381-
Cvtcmd int32
382-
Pccsid int16
383-
Fccsid int16
381+
Cvtcmd int32
382+
Pccsid int16
383+
Fccsid int16
384384
}
385385

386386
type Termios struct {

0 commit comments

Comments
 (0)