aboutsummaryrefslogtreecommitdiffstats
path: root/unsupported/tandem/strdup.c
blob: 45f7676c1cf2845219587c9bdb3e6200ade72b3e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
/*
 * strdup --- duplicate a string
 *
 * We supply this routine for those systems that aren't standard yet.
 */

char *
strdup (str)
register const char *str;
{
	char *p;

	p=(char *)malloc(strlen(str)+1);
	return strcpy(p,str);
}