|
|
|
|
|
|
|
|
|
|
xen-changelog
[Xen-changelog] [xen-unstable] Remus: fix alignment bug in python rtnl l
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1271317360 -3600
# Node ID acba531824354ec390c3e270a96db328362e7b57
# Parent 373daaeb636e8e237c67995718201619d0c0cbc9
Remus: fix alignment bug in python rtnl library
Signed-off-by: Brendan Cully <brendan@xxxxxxxxx>
---
tools/python/xen/remus/netlink.py | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff -r 373daaeb636e -r acba53182435 tools/python/xen/remus/netlink.py
--- a/tools/python/xen/remus/netlink.py Thu Apr 15 08:42:08 2010 +0100
+++ b/tools/python/xen/remus/netlink.py Thu Apr 15 08:42:40 2010 +0100
@@ -77,7 +77,7 @@ class rtattr(object):
return align(self.rta_len)
def pack(self):
- self.rta_len = align(self.fmtlen + len(self.body))
+ self.rta_len = self.fmtlen + align(len(self.body), 2)
s = struct.pack(self.fmt, self.rta_len, self.rta_type) + self.body
pad = self.rta_len - len(s)
if pad:
@@ -88,7 +88,7 @@ class rtattr(object):
args = struct.unpack(self.fmt, msg[:self.fmtlen])
self.rta_len, self.rta_type = args
- self.body = msg[align(self.fmtlen):self.rta_len]
+ self.body = msg[self.fmtlen:self.rta_len]
class rtattrlist(object):
def __init__(self, msg):
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-changelog] [xen-unstable] Remus: fix alignment bug in python rtnl library,
Xen patchbot-unstable <=
|
|
|
|
|