Skip to content

Commit 98722e1

Browse files
SuperQjsimonetti
andauthored
Update minimum Go version (#201)
Go mod version (1.18) is older than depencies (1.20) - github.com/cilium/ebpf - github.com/mdlayher/socket Update `go fmt` for latest Go release. Signed-off-by: SuperQ <[email protected]> Co-authored-by: Jeroen Simonetti <[email protected]>
1 parent 4031cf8 commit 98722e1

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

doc.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@
1717
// netlink traffic inside the kernel. Be aware that this might be overwhelming on a system
1818
// with a lot of netlink traffic.
1919
//
20-
// # modprobe nlmon
21-
// # ip link add type nlmon
22-
// # ip link set nlmon0 up
20+
// # modprobe nlmon
21+
// # ip link add type nlmon
22+
// # ip link set nlmon0 up
2323
//
2424
// At this point use wireshark or tcpdump on the nlmon0 interface to view all netlink traffic.
2525
//

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/jsimonetti/rtnetlink
22

3-
go 1.18
3+
go 1.20
44

55
require (
66
github.com/cilium/ebpf v0.12.3

link.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -163,10 +163,10 @@ func (l *LinkService) Get(index uint32) (LinkMessage, error) {
163163
// ref: https://lwn.net/Articles/236919/
164164
// We explicitly use RTM_NEWLINK to set link attributes instead of
165165
// RTM_SETLINK because:
166-
// - using RTM_SETLINK is actually an old rtnetlink API, not supporting most
167-
// attributes common today
168-
// - using RTM_NEWLINK is the prefered way to create AND update links
169-
// - RTM_NEWLINK is backward compatible to RTM_SETLINK
166+
// - using RTM_SETLINK is actually an old rtnetlink API, not supporting most
167+
// attributes common today
168+
// - using RTM_NEWLINK is the prefered way to create AND update links
169+
// - RTM_NEWLINK is backward compatible to RTM_SETLINK
170170
func (l *LinkService) Set(req *LinkMessage) error {
171171
flags := netlink.Request | netlink.Acknowledge
172172
_, err := l.c.Execute(req, unix.RTM_NEWLINK, flags)

0 commit comments

Comments
 (0)