blob: 6747ef3a2a93f6cdd6fe9660f54dbc3c2be2fd50 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
/*
* lstrdup.c
*/
#include <string.h>
#include <stdlib.h>
#include <com32.h>
char *lstrdup(const char *s)
{
int l = strlen(s) + 1;
char *d = clmalloc(l);
if (d)
memcpy(d, s, l);
return d;
}
|