hub_other.go 418 B

12345678910111213141516171819202122
  1. // +build !linux
  2. package udp
  3. import (
  4. "net"
  5. v2net "v2ray.com/core/common/net"
  6. )
  7. func SetOriginalDestOptions(fd int) error {
  8. return nil
  9. }
  10. func RetrieveOriginalDest(oob []byte) v2net.Destination {
  11. return v2net.Destination{}
  12. }
  13. func ReadUDPMsg(conn *net.UDPConn, payload []byte, oob []byte) (int, int, int, *net.UDPAddr, error) {
  14. nBytes, addr, err := conn.ReadFromUDP(payload)
  15. return nBytes, 0, 0, addr, err
  16. }