Subversion Repositories planix.SVN

Rev

Rev 2 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 - 1
#include <u.h>
2
#include <libc.h>
3
#include "httpd.h"
4
 
5
void*
6
ezalloc(ulong n)
7
{
8
	void *p;
9
 
10
	p = malloc(n);
11
	if(p == nil)
12
		sysfatal("out of memory");
13
	memset(p, 0, n);
14
	return p;
15
}
16
 
17
char*
18
estrdup(char *s)
19
{
20
	s = strdup(s);
21
	if(s == nil)
22
		sysfatal("out of memory");
23
	return s;
24
}
25