[Neo-report] r2481 vincent - /trunk/neo/client/mq.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Thu Dec 9 13:54:27 CET 2010
Author: vincent
Date: Thu Dec 9 13:54:27 2010
New Revision: 2481
Log:
Avoid duplicating "+16" offset in sizeof.
Modified:
trunk/neo/client/mq.py
Modified: trunk/neo/client/mq.py
==============================================================================
--- trunk/neo/client/mq.py [iso-8859-1] (original)
+++ trunk/neo/client/mq.py [iso-8859-1] Thu Dec 9 13:54:27 2010
@@ -109,7 +109,7 @@ class Data(object):
def sizeof(o):
"""This function returns the estimated size of an object."""
if isinstance(o, tuple):
- return sum((len(s)+16 for s in o))
+ return sum((sizeof(s) for s in o))
else:
return len(o)+16
More information about the Neo-report
mailing list