mirror of
https://github.com/yggdrasil-network/yggdrasil-go.git
synced 2025-04-28 22:25:07 +03:00
Accept some golint suggestions (#690)
* Fixed some linter issues * Simplified isBetter method * Accept some linter suggestions * Fix typo Co-authored-by: klesomik <klesomiks@gmail.com> Co-authored-by: Neil Alexander <neilalexander@users.noreply.github.com>
This commit is contained in:
parent
1492738c9e
commit
d6d2d9c19a
15 changed files with 75 additions and 94 deletions
|
@ -28,11 +28,11 @@ func version_getBaseMetadata() version_metadata {
|
|||
}
|
||||
}
|
||||
|
||||
// Gest the length of the metadata for this version, used to know how many bytes to read from the start of a connection.
|
||||
// Gets the length of the metadata for this version, used to know how many bytes to read from the start of a connection.
|
||||
func version_getMetaLength() (mlen int) {
|
||||
mlen += 4 // meta
|
||||
mlen += 1 // ver, as long as it's < 127, which it is in this version
|
||||
mlen += 1 // minorVer, as long as it's < 127, which it is in this version
|
||||
mlen++ // ver, as long as it's < 127, which it is in this version
|
||||
mlen++ // minorVer, as long as it's < 127, which it is in this version
|
||||
mlen += crypto.BoxPubKeyLen // box
|
||||
mlen += crypto.SigPubKeyLen // sig
|
||||
mlen += crypto.BoxPubKeyLen // link
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue