YetAnotherCoupler 3.5.2
Loading...
Searching...
No Matches
ppm_xfuncs.h File Reference

add versions of standard API functions not returning on error More...

#include <stdio.h>
#include <stdlib.h>
#include "ppm/symprefix.h"
Include dependency graph for ppm_xfuncs.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define xcalloc(nmemb, size)    symprefix(xcalloc)((nmemb), (size), __FILE__, __LINE__)
 
#define xmalloc(size)   symprefix(xmalloc)((size), __FILE__, __LINE__)
 
#define xrealloc(ptr, size)    symprefix(xrealloc)((ptr), (size), __FILE__, __LINE__)
 
#define xfopen(path, mode)   symprefix(xfopen)(path, mode, __FILE__, __LINE__)
 
#define xfclose(fp)   symprefix(xfclose)(fp, __FILE__, __LINE__)
 

Functions

void *symprefix xcalloc (size_t nmemb, size_t size, const char *source, int line)
 
void *symprefix xmalloc (size_t size, const char *source, int line)
 
void *symprefix xrealloc (void *ptr, size_t size, const char *source, int line)
 
FILE *symprefix xfopen (const char *path, const char *mode, const char *source, int line)
 
void symprefix xfclose (FILE *fp, const char *source, int line)
 

Detailed Description

add versions of standard API functions not returning on error

Version
1.0
Author
Thomas Jahns jahns.nosp@m.@dkr.nosp@m.z.de

Definition in file ppm_xfuncs.h.

Macro Definition Documentation

◆ xcalloc

#define xcalloc ( nmemb,
size )    symprefix(xcalloc)((nmemb), (size), __FILE__, __LINE__)
Examples
test_interp_grid_parallel.c.

Definition at line 64 of file ppm_xfuncs.h.

◆ xfclose

#define xfclose ( fp)    symprefix(xfclose)(fp, __FILE__, __LINE__)

Definition at line 79 of file ppm_xfuncs.h.

◆ xfopen

#define xfopen ( path,
mode )   symprefix(xfopen)(path, mode, __FILE__, __LINE__)

Definition at line 74 of file ppm_xfuncs.h.

◆ xmalloc

◆ xrealloc

#define xrealloc ( ptr,
size )    symprefix(xrealloc)((ptr), (size), __FILE__, __LINE__)

Definition at line 67 of file ppm_xfuncs.h.

Function Documentation

◆ xcalloc()

void *symprefix xcalloc ( size_t nmemb,
size_t size,
const char * source,
int line )

Definition at line 65 of file xmalloc.c.

◆ xfclose()

void symprefix xfclose ( FILE * fp,
const char * source,
int line )

Definition at line 73 of file xstdio.c.

Here is the call graph for this function:

◆ xfopen()

FILE *symprefix xfopen ( const char * path,
const char * mode,
const char * source,
int line )

Definition at line 54 of file xstdio.c.

Here is the call graph for this function:

◆ xmalloc()

void *symprefix xmalloc ( size_t size,
const char * source,
int line )

Definition at line 74 of file xmalloc.c.

◆ xrealloc()

void *symprefix xrealloc ( void * ptr,
size_t size,
const char * source,
int line )

Definition at line 83 of file xmalloc.c.