mirror of
https://github.com/slackhq/nebula.git
synced 2026-11-17 08:16:52 +01:00
Decode a fragmented handshake message straight into its packet, behind room for the Nebula header, instead of copying it there
This commit is contained in:
1 parent
4b295e086e
commit
cbcf441d7c
8 files changed
+49
-30
No files matched your search
@@ -50,9 +50,10 @@ func (a *Assembly) wouldStore(h Header, sym []byte) int {
|
||||
return len(sym)
|
||||
}
|
||||
|
||||
// Decode reconstructs the message. It requires Add to have reported ready.
|
||||
func (a *Assembly) Decode() ([]byte, error) {
|
||||
return a.dec.Decode()
|
||||
// Decode reconstructs the message and appends it to dst, see fec.Decoder.Decode.
|
||||
// It requires Add to have reported ready.
|
||||
func (a *Assembly) Decode(dst []byte) ([]byte, error) {
|
||||
return a.dec.Decode(dst)
|
||||
}
|
||||
|
||||
// Stored returns the number of symbol bytes held.
|
||||
|
||||
Reference in new issue
Block a user