code: func readNetAddress(r io.Reader, pver uint32, na *NetAddress, ts bool) error {
  	var ip [16]byte
  
  	// NOTE: The bitcoin protocol uses a uint32 for the timestamp so it will
  	// stop working somewhere around 2106.  Also timestamp wasn't added until
  	// protocol version >= NetAddressTimeVersion
  	if ts && pver >= NetAddressTimeVersion {
  		err := readElement(r, (*uint32Time)(&na.Timestamp))
  		if err != nil {
  			return err
  		}
  	}
  
  	err := readElements(r, &na.Services, &ip)
  	if err != nil {
  		return err
  	}
  	// Sigh.  Bitcoin protocol mixes little and big endian.
  	port, err := binarySerializer.Uint16(r, bigEndian)
  	if err != nil {
  		return err
  	}
  
  	*na = NetAddress{
  		Timestamp: na.Timestamp,
  		Services:  na.Services,
  		IP:        net.IP(ip[:]),
  		Port:      port,
  	}
  	return nil
  }
docs: // readNetAddress reads an encoded NetAddress from r depending on the protocol
  // version and whether or not the timestamp is included per ts.  Some messages
  // like version do not include the timestamp.