openalbridge/wrappers.c
changeset 2200 8192be6e3aef
parent 2194 1597710c6118
child 2210 1cb7118a77dd
equal deleted inserted replaced
2199:be265856322f 2200:8192be6e3aef
    23 #endif 
    23 #endif 
    24 	
    24 	
    25 	void *Malloc (size_t nbytes)
    25 	void *Malloc (size_t nbytes)
    26 	{
    26 	{
    27 		void *aptr;
    27 		void *aptr;
    28 		if ( (aptr = malloc(nbytes)) == NULL)
    28 		if ( (aptr = malloc(nbytes)) == NULL) {
    29 			fprintf(stderr, "ERROR: not enough memory! malloc() failed");
    29 			fprintf(stderr, "ERROR: not enough memory! malloc() failed");
       
    30 			exit(-1);
       
    31 		}
    30 		return aptr;
    32 		return aptr;
    31 	}
    33 	}
    32 	
    34 	
    33 	FILE *Fopen (const char *fname, char *mode)
    35 	FILE *Fopen (const char *fname, char *mode)
    34 	{
    36 	{