ref: 09dddd479ccc39088ccbb2f5b514fa9127c74811
parent: 3e33a92bc1f6678b510a4141d3cfb6f61437d9bc
author: Sigrid Solveig Haflínudóttir <ftrvxmtrx@gmail.com>
date: Thu Aug 5 04:18:01 EDT 2021
estrndup: set malloc tag
--- a/util.c
+++ b/util.c
@@ -42,7 +42,9 @@
{
char *s;
- s = emalloc(n+1);
+ s = malloc(n+1);
+ assert(s != nil);
+ setmalloctag(s, getcallerpc(&d));
memmove(s, d, n);
s[n] = 0;