repo.or.cz
/
tftp-hpa.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Update version for release
[tftp-hpa.git]
/
lib
/
xmalloc.c
blob
f234a4608cec5c85f409c1a4ad00d1c6ecb878d4
1
/*
2
* xmalloc.c
3
*
4
* Simple error-checking version of malloc()
5
*
6
*/
7
8
#include
"config.h"
9
10
void
*
xmalloc
(
size_t
size
)
11
{
12
void
*
p
=
malloc
(
size
);
13
14
if
( !
p
) {
15
fprintf
(
stderr
,
"Out of memory!
\n
"
);
16
exit
(
128
);
17
}
18
19
return
p
;
20
}