github.com/code-reading/golang@v0.0.0-20220303082512-ba5bc0e589a3/go/src/net/tcpsockopt_stub.go (about) 1 // Copyright 2009 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 //go:build js && wasm 6 // +build js,wasm 7 8 package net 9 10 import ( 11 "syscall" 12 "time" 13 ) 14 15 func setNoDelay(fd *netFD, noDelay bool) error { 16 return syscall.ENOPROTOOPT 17 } 18 19 func setKeepAlivePeriod(fd *netFD, d time.Duration) error { 20 return syscall.ENOPROTOOPT 21 }