All pastes #459997 Raw Edit

Untitled

public text v1 · immutable
#459997 ·published 2007-04-26 20:06 UTC
rendered paste body
#if 1
//#ifdef NO_BOMBING_MACROS
#  define BU_CKMAG(_ptr, _magic, _str) {
if(!ptr){fprintf(stdout,"NULL ponter in file %s, line %d\n",__FILE__,__LINE__);
 bu_bomb();}}
#  define BU_CKMAG_TCL(_interp, _ptr, _magic, _str) {if(!ptr) bu_bomb();}
#else
#  define BU_CKMAG(_ptr, _magic, _str)  \
        if( !(_ptr) || ( ((long)(_ptr)) & (sizeof(long)-1) ) || \
            *((unsigned long *)(_ptr)) != (unsigned long)(_magic) )  { \
                bu_badmagic( (long *)(_ptr), (unsigned long)_magic, _str, __FILE
        }
#  define BU_CKMAG_TCL(_interp, _ptr, _magic, _str)     \
        if( !(_ptr) || ( ((long)(_ptr)) & (sizeof(long)-1) ) || \
             *((long *)(_ptr)) != (_magic) )  { \
                bu_badmagic_tcl( (_interp), (long *)(_ptr), (unsigned long)_magi
                return TCL_ERROR; \
        }