Updated openstack/openstack
Project: openstack/nova  cf9c7127b5e5445ea497cbaff1f2e14cc84e5d60

Initialize objects field in ObjectsListBase class

Normally the underlying value of an object attribute is set upon first
attempt to set it and would not exist otherwise. This causes the object
attribute access mechanism to fall back to obj_load_attr.

This is mostly fine for a lot of use cases, but it also means that for
ObjectListBase subclasses, it is not possible to construct them empty
and then call list methods on them without resorting to something like:

  myListObject(objects=[])

This patch makes ObjectListBase default it's objects filed to [] if it's
not passed in allowing us to have a cleaner API and call list methods
such as len() on objects constructed on the fly..

Change-Id: Iad1301cc4f88018f10f3dd6c76e35275cd0c51f6