summaryrefslogtreecommitdiff
path: root/ord.c
diff options
context:
space:
mode:
Diffstat (limited to 'ord.c')
-rw-r--r--ord.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/ord.c b/ord.c
index 9c13c93..b5d766e 100644
--- a/ord.c
+++ b/ord.c
@@ -33,11 +33,12 @@ void interchange_ord_checkout(const char *order_profile,
}}, "%s", "ord/checkout");
}
-void interchange_ord_free_order(struct interchange_ord_order *order)
+void interchange_ord_clear_order(struct interchange_ord_order *order)
{
+ for (size_t i = 0; i < order->nitems; i++)
+ interchange_clear_product(&order->items[i].product);
if (order->profile)
free(order->profile);
- free(order);
}
void interchange_ord_free_transaction(struct interchange_ord_transaction