diff --git a/coolamqp/framing/compilation/content_property.py b/coolamqp/framing/compilation/content_property.py index 776291d08c44168bbbc89eed14f0f8cee58e8697..eccf86ec8aea5cdab1a788ddf4ea06ebd0a6c827 100644 --- a/coolamqp/framing/compilation/content_property.py +++ b/coolamqp/framing/compilation/content_property.py @@ -121,11 +121,15 @@ def _compile_particular_content_property_list_class(zpf, fields): return u''.join(mod) +import struct +from coolamqp.framing.base import AMQPContentPropertyList + def compile_particular_content_property_list_class(zpf, fields): import struct from coolamqp.framing.base import AMQPContentPropertyList q = _compile_particular_content_property_list_class(zpf, fields) - - loc = {'struct': struct, 'AMQPContentPropertyList': AMQPContentPropertyList} - exec (q, globals(), loc) + loc = dict(globals(), **{ + 'struct': struct, + 'AMQPContentPropertyList': AMQPContentPropertyList}) + exec (q, loc) return loc['ParticularContentTypeList']