home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Serving the Web
/
ServingTheWeb1995.disc1of1.iso
/
linux
/
slacksrce
/
d
/
libc
/
libc-4.6
/
libc-4
/
libc-linux
/
stdlib
/
fpalloc.c
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
C/C++ Source or Header
|
1993-05-18
|
406 b
|
32 lines
#include <stdlib.h>
#include <memory.h>
#include <endian.h>
#ifdef IEEE_754
#ifdef __BIG_ENDIAN
#define snan_bytes { }
#else
#define snan_bytes { }
#endif
void *
fpalloc (size_t n)
{
void * ptr;
ptr = malloc (n);
if (!ptr) return ptr;
return memtile (ptr, n, snan_bytes, sizeof (snan_bytes));
}
#elese
void *
fpalloc (size_t n)
{
return malloc (n);
}
#endif