Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
go
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
go
Commits
94064548
Commit
94064548
authored
Feb 04, 2013
by
Alex Brainman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
net: use windows sysSocket everywhere
R=golang-dev, bradfitz, dave CC=golang-dev
https://golang.org/cl/7273046
parent
472354f8
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
7 deletions
+2
-7
src/pkg/net/fd_windows.go
src/pkg/net/fd_windows.go
+1
-6
src/pkg/net/interface_windows.go
src/pkg/net/interface_windows.go
+1
-1
No files found.
src/pkg/net/fd_windows.go
View file @
94064548
...
...
@@ -619,15 +619,10 @@ func (fd *netFD) accept(toAddr func(syscall.Sockaddr) Addr) (*netFD, error) {
defer
fd
.
decref
()
// Get new socket.
// See ../syscall/exec_unix.go for description of ForkLock.
syscall
.
ForkLock
.
RLock
()
s
,
err
:=
syscall
.
Socket
(
fd
.
family
,
fd
.
sotype
,
0
)
s
,
err
:=
sysSocket
(
fd
.
family
,
fd
.
sotype
,
0
)
if
err
!=
nil
{
syscall
.
ForkLock
.
RUnlock
()
return
nil
,
&
OpError
{
"socket"
,
fd
.
net
,
fd
.
laddr
,
err
}
}
syscall
.
CloseOnExec
(
s
)
syscall
.
ForkLock
.
RUnlock
()
// Associate our new socket with IOCP.
onceStartServer
.
Do
(
startServer
)
...
...
src/pkg/net/interface_windows.go
View file @
94064548
...
...
@@ -38,7 +38,7 @@ func getAdapterList() (*syscall.IpAdapterInfo, error) {
}
func
getInterfaceList
()
([]
syscall
.
InterfaceInfo
,
error
)
{
s
,
err
:=
sys
call
.
Socket
(
syscall
.
AF_INET
,
syscall
.
SOCK_DGRAM
,
syscall
.
IPPROTO_UDP
)
s
,
err
:=
sysSocket
(
syscall
.
AF_INET
,
syscall
.
SOCK_DGRAM
,
syscall
.
IPPROTO_UDP
)
if
err
!=
nil
{
return
nil
,
os
.
NewSyscallError
(
"Socket"
,
err
)
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment