fixed a bug in mavl_add FossilOrigin-Name: 4b040305182ef40f6f053fe1d84ea15f533e931c9d665b513b9a644592519f3e
11 lines
191 B
C
11 lines
191 B
C
#include <string.h>
|
|
#include <stdlib.h>
|
|
|
|
char *cw_strdup(const char *s) {
|
|
size_t size = strlen(s) + 1;
|
|
char *p = malloc(size);
|
|
if (p)
|
|
memcpy(p, s, size);
|
|
return p;
|
|
}
|