projects
/
pintos-anon
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Rename xmalloc() as malloc_or_panic(),
[pintos-anon]
/
src
/
threads
/
malloc.c
diff --git
a/src/threads/malloc.c
b/src/threads/malloc.c
index 9c83e3d438f780199166c3c92aa0893aa842f98f..4f8675cf90572164dbf715a35cfe33fc876e1f24 100644
(file)
--- a/
src/threads/malloc.c
+++ b/
src/threads/malloc.c
@@
-158,7
+158,7
@@
malloc (size_t size)
kernel to panic in normal operation, so this function should
only be used during kernel initialization. */
void *
kernel to panic in normal operation, so this function should
only be used during kernel initialization. */
void *
-
xmallo
c (size_t size)
+
malloc_or_pani
c (size_t size)
{
void *p = malloc (size);
if (p == NULL && size > 0)
{
void *p = malloc (size);
if (p == NULL && size > 0)
@@
-192,7
+192,7
@@
calloc (size_t a, size_t b)
kernel to panic in normal operation, so this function should
only be used during kernel initialization. */
void *
kernel to panic in normal operation, so this function should
only be used during kernel initialization. */
void *
-
xcallo
c (size_t a, size_t b)
+
calloc_or_pani
c (size_t a, size_t b)
{
void *p = calloc (a, b);
if (p == NULL && a > 0 && b > 0)
{
void *p = calloc (a, b);
if (p == NULL && a > 0 && b > 0)