mirror of
https://github.com/v2fly/v2ray-core.git
synced 2024-12-22 01:57:12 -05:00
fix compile warning
This commit is contained in:
parent
582438ce5e
commit
42417cab17
@ -19,8 +19,8 @@ func (v *SRTP) Size() int {
|
||||
|
||||
func (v *SRTP) Write(b []byte) (int, error) {
|
||||
v.number++
|
||||
b = serial.Uint16ToBytes(v.number, b[:0])
|
||||
b = serial.Uint16ToBytes(v.number, b)
|
||||
serial.Uint16ToBytes(v.number, b[:0])
|
||||
serial.Uint16ToBytes(v.number, b[:2])
|
||||
return 4, nil
|
||||
}
|
||||
|
||||
|
@ -19,8 +19,9 @@ func (v *UTP) Size() int {
|
||||
}
|
||||
|
||||
func (v *UTP) Write(b []byte) (int, error) {
|
||||
b = serial.Uint16ToBytes(v.connectionId, b[:0])
|
||||
b = append(b, v.header, v.extension)
|
||||
serial.Uint16ToBytes(v.connectionId, b[:0])
|
||||
b[2] = v.header
|
||||
b[3] = v.extension
|
||||
return 4, nil
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user