Skip to content

Commit 603182f

Browse files
committed
Reformat code
1 parent 6e2993d commit 603182f

32 files changed

+180
-139
lines changed

cmd/ipset-test/main.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build linux
12
// +build linux
23

34
package main

conntrack_unspecified.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build !linux
12
// +build !linux
23

34
package netlink

devlink_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build linux
12
// +build linux
23

34
package netlink

fou_linux.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build linux
12
// +build linux
23

34
package netlink

fou_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build linux
12
// +build linux
23

34
package netlink

fou_unspecified.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build !linux
12
// +build !linux
23

34
package netlink

genetlink_unspecified.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build !linux
12
// +build !linux
23

34
package netlink

gtp_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build linux
12
// +build linux
23

34
package netlink

handle_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build linux
12
// +build linux
23

34
package netlink

handle_unspecified.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build !linux
12
// +build !linux
23

34
package netlink

link.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1210,6 +1210,7 @@ func (gtp *GTP) Type() string {
12101210
}
12111211

12121212
// Virtual XFRM Interfaces
1213+
//
12131214
// Named "xfrmi" to prevent confusion with XFRM objects
12141215
type Xfrmi struct {
12151216
LinkAttrs

link_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -396,7 +396,7 @@ func compareGretap(t *testing.T, expected, actual *Gretap) {
396396

397397
if actual.FlowBased != expected.FlowBased {
398398
t.Fatal("Gretap.FlowBased doesn't match")
399-
}
399+
}
400400
}
401401

402402
func compareGretun(t *testing.T, expected, actual *Gretun) {

neigh_test.go

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build linux
12
// +build linux
23

34
package netlink
@@ -324,7 +325,7 @@ func TestNeighSubscribe(t *testing.T) {
324325
if err := NeighAdd(entry); err != nil {
325326
t.Errorf("Failed to NeighAdd: %v", err)
326327
}
327-
if !expectNeighUpdate(ch, []NeighUpdate{NeighUpdate{
328+
if !expectNeighUpdate(ch, []NeighUpdate{{
328329
Type: unix.RTM_NEWNEIGH,
329330
Neigh: *entry,
330331
}}) {
@@ -333,7 +334,7 @@ func TestNeighSubscribe(t *testing.T) {
333334
if err := NeighDel(entry); err != nil {
334335
t.Fatal(err)
335336
}
336-
if !expectNeighUpdate(ch, []NeighUpdate{NeighUpdate{
337+
if !expectNeighUpdate(ch, []NeighUpdate{{
337338
Type: unix.RTM_NEWNEIGH,
338339
Neigh: Neigh{
339340
State: NUD_FAILED,
@@ -386,7 +387,7 @@ func TestNeighSubscribeWithOptions(t *testing.T) {
386387
if err != nil {
387388
t.Errorf("Failed to NeighAdd: %v", err)
388389
}
389-
if !expectNeighUpdate(ch, []NeighUpdate{NeighUpdate{
390+
if !expectNeighUpdate(ch, []NeighUpdate{{
390391
Type: unix.RTM_NEWNEIGH,
391392
Neigh: *entry,
392393
}}) {
@@ -440,7 +441,7 @@ func TestNeighSubscribeAt(t *testing.T) {
440441
if err != nil {
441442
t.Errorf("Failed to NeighAdd: %v", err)
442443
}
443-
if !expectNeighUpdate(ch, []NeighUpdate{NeighUpdate{
444+
if !expectNeighUpdate(ch, []NeighUpdate{{
444445
Type: unix.RTM_NEWNEIGH,
445446
Neigh: *entry,
446447
}}) {
@@ -523,11 +524,11 @@ func TestNeighSubscribeListExisting(t *testing.T) {
523524
}
524525

525526
if !expectNeighUpdate(ch, []NeighUpdate{
526-
NeighUpdate{
527+
{
527528
Type: unix.RTM_NEWNEIGH,
528529
Neigh: *entry1,
529530
},
530-
NeighUpdate{
531+
{
531532
Type: unix.RTM_NEWNEIGH,
532533
Neigh: *entryBr,
533534
},
@@ -547,7 +548,7 @@ func TestNeighSubscribeListExisting(t *testing.T) {
547548
t.Errorf("Failed to NeighAdd: %v", err)
548549
}
549550

550-
if !expectNeighUpdate(ch, []NeighUpdate{NeighUpdate{
551+
if !expectNeighUpdate(ch, []NeighUpdate{{
551552
Type: unix.RTM_NEWNEIGH,
552553
Neigh: *entry2,
553554
}}) {

netlink_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build linux
12
// +build linux
23

34
package netlink

netlink_unspecified.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build !linux
12
// +build !linux
23

34
package netlink

netns_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build linux
12
// +build linux
23

34
package netlink

netns_unspecified.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//go:build !linux
12
// +build !linux
23

34
package netlink

0 commit comments

Comments
 (0)