aboutsummaryrefslogtreecommitdiff
path: root/udppacket.go
diff options
context:
space:
mode:
Diffstat (limited to 'udppacket.go')
-rw-r--r--udppacket.go6
1 files changed, 0 insertions, 6 deletions
diff --git a/udppacket.go b/udppacket.go
index 8cecfb0..fd52a61 100644
--- a/udppacket.go
+++ b/udppacket.go
@@ -8,16 +8,12 @@ const (
defSize = 1024
)
-//
// UDPPacket wrap the slice of bytes for easy manipulation.
-//
type UDPPacket struct {
Bytes []byte
}
-//
// NewUDPPacket will create and initialize UDP packet.
-//
func NewUDPPacket(size uint32) (p *UDPPacket) {
if size <= 0 {
size = defSize
@@ -29,10 +25,8 @@ func NewUDPPacket(size uint32) (p *UDPPacket) {
return
}
-//
// Reset will set the content of packet data to zero, so it can be used
// against on Read().
-//
func (p *UDPPacket) Reset() {
p.Bytes[0] = 0
for x := 1; x < len(p.Bytes); x *= 2 {