From bcbf6e2049191fb218ff288106d0744430011dc9 Mon Sep 17 00:00:00 2001 From: Ian Campbell Date: Thu, 19 Aug 2010 15:20:22 +0100 Subject: libxl: generate destructors for each libxl defined type I chose the name "_destroy" rather than "_free" because the destructor functions will free only the members of a type recursively but will not free the actual type structure itself. The allocation of the type is typically done by the caller and may not be a single allocation, e.g. lists/arrays of types or embedded in other structures etc. The exceptions to this rule are libxl_string_list_destroy and libxl_key_value_list_destroy but I'm not 100% convinced they are exceptions (since they are kind-of opaque) and I couldn't see a cleanerway to express this concept. I have made a best effort attempt to implement these functions sanely but since as far as I can tell nothing in the current code base ever sets libxl_domain_create_info.{xsdata,platformdata} I'm flying somewhat blind. [PATCH 05 of 16 of libxl: autogenerate type definitions and destructor functions] Signed-off-by: Ian Campbell Signed-off-by: Ian Jackson --- .hgignore | 1 + 1 file changed, 1 insertion(+) (limited to '.hgignore') diff --git a/.hgignore b/.hgignore index d39427946b..2ab5724a29 100644 --- a/.hgignore +++ b/.hgignore @@ -182,6 +182,7 @@ ^tools/libxen/test/test_bindings$ ^tools/libxen/test/test_event_handling$ ^tools/libxl/_.*\.h$ +^tools/libxl/_.*\.c$ ^tools/libxl/libxlu_cfg_y\.output$ ^tools/libxl/xl$ ^tools/libaio/src/.*\.ol$ -- cgit v1.2.3