summaryrefslogtreecommitdiff
path: root/damage/damage.go
diff options
context:
space:
mode:
authorAndrew Gallant <[email protected]>2013-12-28 09:33:09 -0500
committerAndrew Gallant <[email protected]>2013-12-28 09:33:09 -0500
commit34dd98df049a0a6ecf661ff9fdfe31292688040a (patch)
treeb2cbe9e643ec6271bbcbdf8c1030a56575d57109 /damage/damage.go
parent9071499d31a04ae4e2e545e2f2227545d32187a4 (diff)
When writing, don't pad the length of bytes produced from inner
structs/unions. Each type should take care of its own padding. Close #14.
Diffstat (limited to 'damage/damage.go')
-rw-r--r--damage/damage.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/damage/damage.go b/damage/damage.go
index 0ab7668..e94936d 100644
--- a/damage/damage.go
+++ b/damage/damage.go
@@ -162,13 +162,13 @@ func (v NotifyEvent) Bytes() []byte {
{
structBytes := v.Area.Bytes()
copy(buf[b:], structBytes)
- b += xgb.Pad(len(structBytes))
+ b += len(structBytes)
}
{
structBytes := v.Geometry.Bytes()
copy(buf[b:], structBytes)
- b += xgb.Pad(len(structBytes))
+ b += len(structBytes)
}
return buf