summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id>2023-02-07 13:09:10 +0800
committerꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id>2023-02-07 13:09:10 +0800
commitbbda409c41098831ea48689145a44b8a6eaf6b20 (patch)
treeef86996aaf7f403193b1ea68313d7090fe23bb37
parent254078e4279addf0a9c97dcacbf750522cc9cfcd (diff)
Free the profile when freeing order
-rw-r--r--ord.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/ord.c b/ord.c
index 3997b61..5d2265a 100644
--- a/ord.c
+++ b/ord.c
@@ -83,6 +83,8 @@ void interchange_ord_checkout(const struct interchange_ord_order *order, const s
void interchange_ord_free(struct interchange_ord_order *order)
{
+ if (order->profile)
+ free(order->profile);
for (size_t i = 0; i < order->nitems; i++)
interchange_free_product(order->items[i]->product);
}