mirror of
https://github.com/v2ray/v2ray-core.git
synced 2026-11-25 07:20:44 +00:00
refactor bytes functions
This commit is contained in:
16 files changed
+78
-64
No files matched your search
@@ -94,12 +94,12 @@ func (this *CommandSwitchAccountFactory) Marshal(command interface{}, writer io.
|
||||
writer.Write([]byte(hostStr))
|
||||
}
|
||||
|
||||
writer.Write(cmd.Port.Bytes())
|
||||
writer.Write(cmd.Port.Bytes(nil))
|
||||
|
||||
idBytes := cmd.ID.Bytes()
|
||||
writer.Write(idBytes)
|
||||
|
||||
writer.Write(serial.Uint16ToBytes(cmd.AlterIds))
|
||||
writer.Write(serial.Uint16ToBytes(cmd.AlterIds, nil))
|
||||
writer.Write([]byte{byte(cmd.Level)})
|
||||
|
||||
writer.Write([]byte{cmd.ValidMin})
|
||||
|
||||
Reference in new issue
Block a user