mirror of
https://github.com/genodelabs/genode.git
synced 2025-04-07 19:34:56 +00:00
parent
dd6bd0f880
commit
2b21f41495
@ -17,7 +17,7 @@
|
||||
#include <stdarg.h>
|
||||
#include <stddef.h>
|
||||
|
||||
#define FILE int
|
||||
#define FILE void
|
||||
|
||||
#define EOF (-1)
|
||||
|
||||
|
@ -14,9 +14,8 @@
|
||||
#include <base/log.h>
|
||||
#include <base/sleep.h>
|
||||
|
||||
extern "C" void *abort(void)
|
||||
extern "C" void abort(void)
|
||||
{
|
||||
Genode::warning("abort called");
|
||||
Genode::sleep_forever();
|
||||
return 0;
|
||||
}
|
||||
|
@ -32,7 +32,7 @@ static Allocator &alloc()
|
||||
void mini_c_init(Allocator &alloc) { _alloc_ptr = &alloc; }
|
||||
|
||||
|
||||
extern "C" void *malloc(unsigned size)
|
||||
extern "C" void *malloc(size_t size)
|
||||
{
|
||||
/*
|
||||
* We store the size of the allocation at the very
|
||||
@ -50,7 +50,7 @@ extern "C" void *malloc(unsigned size)
|
||||
}
|
||||
|
||||
|
||||
extern "C" void *calloc(unsigned nmemb, unsigned size)
|
||||
extern "C" void *calloc(size_t nmemb, size_t size)
|
||||
{
|
||||
void *addr = malloc(nmemb*size);
|
||||
memset(addr, 0, nmemb*size);
|
||||
|
Loading…
x
Reference in New Issue
Block a user