]> Cypherpunks.ru repositories - nncp.git/blobdiff - src/pkt.go
Replace zlib with zstd
[nncp.git] / src / pkt.go
index cb75c237286383bbd0962cbfdeb01e0445c55acc..2fab844422486793be179dd571ef5f77386a3e1c 100644 (file)
@@ -51,7 +51,7 @@ const (
 )
 
 var (
-       MagicNNCPPv2 [8]byte = [8]byte{'N', 'N', 'C', 'P', 'P', 0, 0, 2}
+       MagicNNCPPv3 [8]byte = [8]byte{'N', 'N', 'C', 'P', 'P', 0, 0, 3}
        MagicNNCPEv4 [8]byte = [8]byte{'N', 'N', 'C', 'P', 'E', 0, 0, 4}
        BadMagic     error   = errors.New("Unknown magic number")
        BadPktType   error   = errors.New("Unknown packet type")
@@ -123,7 +123,7 @@ func NewPkt(typ PktType, nice uint8, path []byte) (*Pkt, error) {
                return nil, errors.New("Too long path")
        }
        pkt := Pkt{
-               Magic:   MagicNNCPPv2,
+               Magic:   MagicNNCPPv3,
                Type:    typ,
                Nice:    nice,
                PathLen: uint8(len(path)),