mirror of
https://github.com/yggdrasil-network/yggdrasil-go.git
synced 2025-04-29 14:45:07 +03:00
Spelling fixes
Spelling fixes done by running aspell over it.
This commit is contained in:
parent
0dfdc789d3
commit
3bebc6d334
5 changed files with 9 additions and 9 deletions
|
@ -17,7 +17,7 @@ type Adapter struct {
|
|||
recv <-chan []byte
|
||||
}
|
||||
|
||||
// Initialises the adapter.
|
||||
// Initializes the adapter.
|
||||
func (adapter *Adapter) init(core *Core, send chan<- []byte, recv <-chan []byte) {
|
||||
adapter.core = core
|
||||
adapter.send = send
|
||||
|
|
|
@ -56,7 +56,7 @@ func ipv6Header_Marshal(h *ipv6.Header) ([]byte, error) {
|
|||
return b, nil
|
||||
}
|
||||
|
||||
// Initialises the ICMPv6 module by assigning our link-local IPv6 address and
|
||||
// Initializes the ICMPv6 module by assigning our link-local IPv6 address and
|
||||
// our MAC address. ICMPv6 messages will always appear to originate from these
|
||||
// addresses.
|
||||
func (i *icmpv6) init(t *tunAdapter) {
|
||||
|
|
|
@ -41,7 +41,7 @@ type nodeinfoReqRes struct {
|
|||
NodeInfo nodeinfoPayload
|
||||
}
|
||||
|
||||
// Initialises the nodeinfo cache/callback maps, and starts a goroutine to keep
|
||||
// Initializes the nodeinfo cache/callback maps, and starts a goroutine to keep
|
||||
// the cache/callback maps clean of stale entries
|
||||
func (m *nodeinfo) init(core *Core) {
|
||||
m.core = core
|
||||
|
|
|
@ -14,7 +14,7 @@ import (
|
|||
)
|
||||
|
||||
// The peers struct represents peers with an active connection.
|
||||
// Incomping packets are passed to the corresponding peer, which handles them somehow.
|
||||
// Incoming packets are passed to the corresponding peer, which handles them somehow.
|
||||
// In most cases, this involves passing the packet to the handler for outgoing traffic to another peer.
|
||||
// In other cases, it's link protocol traffic used to build the spanning tree, in which case this checks signatures and passes the message along to the switch.
|
||||
type peers struct {
|
||||
|
@ -341,7 +341,7 @@ func (p *peer) handleSwitchMsg(packet []byte) {
|
|||
}
|
||||
|
||||
// This generates the bytes that we sign or check the signature of for a switchMsg.
|
||||
// It begins with the next node's key, followed by the root and the timetsamp, followed by coords being advertised to the next node.
|
||||
// It begins with the next node's key, followed by the root and the timestamp, followed by coords being advertised to the next node.
|
||||
func getBytesForSig(next *crypto.SigPubKey, msg *switchMsg) []byte {
|
||||
var loc switchLocator
|
||||
for _, hop := range msg.Hops {
|
||||
|
|
|
@ -74,7 +74,7 @@ func (iface *tcpInterface) connect(addr string, intf string) {
|
|||
iface.call(addr, nil, intf)
|
||||
}
|
||||
|
||||
// Attempst to initiate a connection to the provided address, viathe provided socks proxy address.
|
||||
// Attempts to initiate a connection to the provided address, via the provided socks proxy address.
|
||||
func (iface *tcpInterface) connectSOCKS(socksaddr, peeraddr string) {
|
||||
iface.call(peeraddr, &socksaddr, "")
|
||||
}
|
||||
|
@ -370,7 +370,7 @@ func (iface *tcpInterface) handler(sock net.Conn, incoming bool) {
|
|||
return
|
||||
}
|
||||
|
||||
// This reads from the socket into a []byte buffer for incomping messages.
|
||||
// This reads from the socket into a []byte buffer for incoming messages.
|
||||
// It copies completed messages out of the cache into a new slice, and passes them to the peer struct via the provided `in func([]byte)` argument.
|
||||
// Then it shifts the incomplete fragments of data forward so future reads won't overwrite it.
|
||||
func (iface *tcpInterface) reader(sock net.Conn, in func([]byte)) error {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue