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

Unified Diff: ipv4/sockopt_freebsd.go

Issue 97800043: code review 97800043: go.net/ipv4: add support for dragonfly (Closed)
Patch Set: diff -r 9c33002573cb https://code.google.com/p/go.net Created 10 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ipv4/sockopt_bsd.go ('k') | ipv4/sockopt_linux.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ipv4/sockopt_freebsd.go
===================================================================
deleted file mode 100644
--- a/ipv4/sockopt_freebsd.go
+++ /dev/null
@@ -1,22 +0,0 @@
-// Copyright 2012 The Go Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style
-// license that can be found in the LICENSE file.
-
-package ipv4
-
-import (
- "os"
- "syscall"
-)
-
-func ipv4SendSourceAddress(fd int) (bool, error) {
- v, err := syscall.GetsockoptInt(fd, ianaProtocolIP, syscall.IP_SENDSRCADDR)
- if err != nil {
- return false, os.NewSyscallError("getsockopt", err)
- }
- return v == 1, nil
-}
-
-func setIPv4SendSourceAddress(fd int, v bool) error {
- return os.NewSyscallError("setsockopt", syscall.SetsockoptInt(fd, ianaProtocolIP, syscall.IP_SENDSRCADDR, boolint(v)))
-}
« no previous file with comments | « ipv4/sockopt_bsd.go ('k') | ipv4/sockopt_linux.go » ('j') | no next file with comments »

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