summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id>2022-08-22 21:17:52 +0800
committerꦌꦫꦶꦏ꧀ꦦꦿꦧꦮꦑꦩꦭ꧀ <erik@darapsa.co.id>2022-08-22 21:17:52 +0800
commit97dec036095480b3ebaf56028f549d4cd694c403 (patch)
treed12eab66818f188b5fb4a941de00e1348fa0bcd3
parentf91513bcc8f2f001bb3096a2793f16f052f74861 (diff)
Array setter doesn't free
-rw-r--r--pikul.i2
1 files changed, 0 insertions, 2 deletions
diff --git a/pikul.i b/pikul.i
index c045603..bc7a1b4 100644
--- a/pikul.i
+++ b/pikul.i
@@ -8,8 +8,6 @@
char *provisions[3];
void provisions_set(int i, char *val)
{
- if (provisions[i])
- free(provisions[i]);
provisions[i] = (char *)malloc(strlen(val) + 1);
strcpy(provisions[i], val);
}