Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(360)

Delta Between Two Patch Sets: ipv4/control_bsd.go

Issue 6482044: code review 6482044: go.net/ipv4: new package (Closed)
Left Patch Set: diff -r 147c4a6dca9b https://code.google.com/p/go.net Created 11 years, 6 months ago
Right Patch Set: diff -r 2513e9008213 https://code.google.com/p/go.net Created 11 years, 6 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « ipv4/control.go ('k') | ipv4/control_linux.go » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
1 // Copyright 2012 The Go Authors. All rights reserved. 1 // Copyright 2012 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style 2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file. 3 // license that can be found in the LICENSE file.
4 4
5 // +build darwin freebsd netbsd openbsd 5 // +build darwin freebsd netbsd openbsd
6 6
7 package ipv4 7 package ipv4
8 8
9 import ( 9 import (
10 "net" 10 "net"
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 v := m.Data[:4] 99 v := m.Data[:4]
100 cm.Dst = net.IPv4(v[0], v[1], v[2], v[3]) 100 cm.Dst = net.IPv4(v[0], v[1], v[2], v[3])
101 case syscall.IP_RECVIF: 101 case syscall.IP_RECVIF:
102 sadl := (*syscall.SockaddrDatalink)(unsafe.Pointer(&m.Da ta[0])) 102 sadl := (*syscall.SockaddrDatalink)(unsafe.Pointer(&m.Da ta[0]))
103 cm.IfIndex = int(sadl.Index) 103 cm.IfIndex = int(sadl.Index)
104 } 104 }
105 } 105 }
106 return cm, nil 106 return cm, nil
107 } 107 }
108 108
109 func marshalControlMessage(cm *ControlMessage) []byte { 109 func marshalControlMessage(cm *ControlMessage) []byte {
dfc 2012/09/05 06:27:16 is this a TODO here? Plan9 has it down as to be im
mikio 2012/09/06 10:43:48 Done.
110 // TODO(mikio): Implement IP_PKTINFO stuff when OS X 10.8 comes
110 return nil 111 return nil
111 } 112 }
LEFTRIGHT

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b