add versions of standard API functions not returning on error
More...
#include <stdio.h>
#include <stdlib.h>
#include "core/symprefix.h"
Go to the source code of this file.
|
#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__) |
|
#define | xfputc(c, stream) SymPrefix(xfputc)((c),(stream), __FILE__, __LINE__) |
|
|
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) |
|
int SymPrefix | xfputc (int c, FILE *stream, const char *source, int line) |
|
add versions of standard API functions not returning on error
- Copyright
- (C) 2012 Thomas Jahns jahns.nosp@m.@dkr.nosp@m.z.de
- Version
- 1.0
- Author
- Thomas Jahns jahns.nosp@m.@dkr.nosp@m.z.de
Definition in file ppm_xfuncs.h.
◆ xcalloc
#define xcalloc |
( |
| nmemb, |
|
|
| size ) SymPrefix(xcalloc)((nmemb), (size), __FILE__, __LINE__) |
◆ xfclose
#define xfclose |
( |
| fp | ) |
SymPrefix(xfclose)(fp, __FILE__, __LINE__) |
◆ xfopen
#define xfopen |
( |
| path, |
|
|
| mode ) SymPrefix(xfopen)(path, mode, __FILE__, __LINE__) |
◆ xfputc
#define xfputc |
( |
| c, |
|
|
| stream ) SymPrefix(xfputc)((c),(stream), __FILE__, __LINE__) |
◆ xmalloc
#define xmalloc |
( |
| size | ) |
SymPrefix(xmalloc)((size), __FILE__, __LINE__) |
◆ xrealloc
#define xrealloc |
( |
| ptr, |
|
|
| size ) SymPrefix(xrealloc)((ptr), (size), __FILE__, __LINE__) |
◆ xcalloc()
void *SymPrefix xcalloc |
( |
size_t | nmemb, |
|
|
size_t | size, |
|
|
const char * | source, |
|
|
int | line ) |
◆ xfclose()
void SymPrefix xfclose |
( |
FILE * | fp, |
|
|
const char * | source, |
|
|
int | line ) |
◆ xfopen()
FILE *SymPrefix xfopen |
( |
const char * | path, |
|
|
const char * | mode, |
|
|
const char * | source, |
|
|
int | line ) |
◆ xfputc()
int SymPrefix xfputc |
( |
int | c, |
|
|
FILE * | stream, |
|
|
const char * | source, |
|
|
int | line ) |
◆ xmalloc()
void *SymPrefix xmalloc |
( |
size_t | size, |
|
|
const char * | source, |
|
|
int | line ) |
◆ xrealloc()
void *SymPrefix xrealloc |
( |
void * | ptr, |
|
|
size_t | size, |
|
|
const char * | source, |
|
|
int | line ) |