memory leak: at_travelunit contains a quicklist, needs custom cleanup code.

This commit is contained in:
Enno Rehling 2015-10-13 22:09:41 +02:00
parent 7e9c36b599
commit 7c2c520911
1 changed files with 6 additions and 1 deletions

View File

@ -38,13 +38,18 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#include <assert.h>
#include <string.h>
static void travel_done(attrib *a) {
quicklist *ql = (quicklist *)a->data.v;
ql_free(ql);
}
/*********************/
/* at_travelunit */
/*********************/
attrib_type at_travelunit = {
"travelunit",
DEFAULT_INIT,
DEFAULT_FINALIZE,
travel_done,
DEFAULT_AGE,
NO_WRITE,
NO_READ