Warning: Attempt to read property "date" on null in /usr/local/www/websvn.planix.org/blame.php on line 247

Warning: Attempt to read property "msg" on null in /usr/local/www/websvn.planix.org/blame.php on line 247
WebSVN – planix.SVN – Blame – /os/branches/feature_tlsv12/sys/src/liboventi/strdup.c – Rev 2

Subversion Repositories planix.SVN

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 - 1
#include <u.h>
2
#include <libc.h>
3
#include <oventi.h>
4
 
5
char*
6
vtStrDup(char *s)
7
{
8
	int n;
9
	char *ss;
10
 
11
	if(s == nil)
12
		return nil;
13
	n = strlen(s) + 1;
14
	ss = vtMemAlloc(n);
15
	memmove(ss, s, n);
16
	setmalloctag(ss, getcallerpc(&s));
17
	return ss;
18
}
19