Commit 32a590b7 authored by thomas.forbriger's avatar thomas.forbriger
Browse files

[TASK] (libs): remove tfmacros.h

This is a legacy commit from before 2015-03-01.
It may be incomplete as well as inconsistent.
See COPYING.legacy and README.history for details.

tfmacros.h is obsolete
parent 61cbf6ca
/* this is <tfmacros.h>
*
* this file contains some frequently used preprocessor macros
*
* 23/4/1997 Thomas Forbriger
*
* ----
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
* ----
*
*/
#ifndef _TF_TFMACROS_H
#define _TF_TFMACROS_H
#warning "tfmacros.h is deprecated and will disappear in the future"
/* #include <stdlib.h> */
/*
* macros
*/
#ifndef EXIT_SUCCESS
#define EXIT_SUCCESS 0
#endif
#ifndef EXIT_FAILURE
#define EXIT_FAILURE 1
#endif
#ifndef CHECKERROR
#define CHECKERROR( EXPR , SUB, STR )\
if ( EXPR ) { fprintf(stderr, "ERROR (%s):\n %s\n", SUB, STR );\
exit(EXIT_FAILURE); }
#endif
#ifndef RETURNERROR
#define RETURNERROR( EXPR , SUB, STR, CODE )\
if ( EXPR ) { fprintf(stderr, "ERROR (%s):\n %s\n", SUB, STR );\
return(CODE); }
#endif
#ifndef FRETURNERROR
#define FRETURNERROR( EXPR , SUB, STR, FILENAME, CODE )\
if ( EXPR ) { fprintf(stderr, "ERROR (%s %s):\n %s\n", \
SUB, FILENAME, STR );\
return(CODE); }
#endif
#ifndef CHECKWARNING
#define CHECKWARNING( EXPR , SUB, STR )\
if ( EXPR ) { fprintf(stderr, "WARNING (%s):\n %s\n", SUB, STR ); }
#endif
#ifndef SETFREE
#define SETFREE( PTR ) \
if (PTR!=NULL) { free(PTR); PTR=NULL; }
#endif
#endif /* _TF_TFMACROS_H */
/***** END OF tfmacros.h *****/
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment