From 9e68c150e16a2e6716ffff032225501480336546 Mon Sep 17 00:00:00 2001 From: v2ray Date: Tue, 23 Feb 2016 22:51:08 +0100 Subject: [PATCH] timestamp in protocol --- common/protocol/time.go | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 common/protocol/time.go diff --git a/common/protocol/time.go b/common/protocol/time.go new file mode 100644 index 00000000..bb3d61a0 --- /dev/null +++ b/common/protocol/time.go @@ -0,0 +1,11 @@ +package protocol + +import ( + "github.com/v2ray/v2ray-core/common/serial" +) + +type Timestamp int64 + +func (this Timestamp) Bytes() []byte { + return serial.Int64Literal(this).Bytes() +}