From 9beee6344f95d487c30e6bcdafaf9596716236c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=A6=8C=20=EA=A6=AB=EA=A6=B6=20=EA=A6=8F=EA=A7=80?= =?UTF-8?q?=EA=A6=A6=EA=A6=BF=20=EA=A6=A7=20=EA=A6=AE=20=EA=A6=91=20?= =?UTF-8?q?=EA=A6=A9=20=EA=A6=AD=EA=A7=80?= Date: Fri, 27 Sep 2019 21:47:08 +0800 Subject: Revert "Freeing the catalog should be the memory allocator's responsibility" This reverts commit 62d23b4337b83d2a2933c4fa4233906030e09fb6. # Conflicts: # libicclient --- catalog.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/catalog.cxx b/catalog.cxx index 8664cdc..17702bc 100644 --- a/catalog.cxx +++ b/catalog.cxx @@ -51,9 +51,11 @@ namespace ICClient { void Catalog::update(icclient_catalog* catalog) { - if (catalog) + if (catalog) { for (size_t i = 0; i < catalog->length; i++) addProduct(Product{catalog->products[i]}); + icclient_product_freecatalog(catalog); + } emit updated(); } -- cgit v1.2.3