BRL-CAD
#include "bu/magic.h"
Include dependency graph for magic.c:

Go to the source code of this file.

Functions

const char * bu_identify_magic (register uint32_t magic)
 

Detailed Description

Routines involved with handling "magic numbers" used to identify various in-memory data structures. Magic numbers provide a means to perform run-time sanity checks for memory corruption and uninitialized data.

The one ugly thing about this implementation is that every BRL-CAD structure needs to have its magic number registered here and in the header.

Definition in file magic.c.

Function Documentation

const char* bu_identify_magic ( register uint32_t  magic)

Definition at line 24 of file magic.c.

References ANIMATE_MAGIC, BN_GAUSS_MAGIC, BN_POLY_MAGIC, BN_SPM_MAGIC, BN_TABDATA_MAGIC, BN_TABLE_MAGIC, BN_TOL_MAGIC, BN_UNIF_MAGIC, BN_VLBLOCK_MAGIC, BN_VLIST_MAGIC, BU_AVS_MAGIC, BU_BITV_MAGIC, BU_COLOR_MAGIC, BU_EXTERNAL_MAGIC, BU_HASH_ENTRY_MAGIC, BU_HASH_RECORD_MAGIC, BU_HASH_TBL_MAGIC, BU_HIST_MAGIC, BU_HOOK_LIST_MAGIC, BU_IMAGE_FILE_MAGIC, BU_LIST_HEAD_MAGIC, BU_MAPPED_FILE_MAGIC, BU_PTBL_MAGIC, BU_RB_LIST_MAGIC, BU_RB_NODE_MAGIC, BU_RB_PKG_MAGIC, BU_RB_TREE_MAGIC, BU_VLB_MAGIC, BU_VLS_MAGIC, CURVE_BEZIER_MAGIC, CURVE_CARC_MAGIC, CURVE_LSEG_MAGIC, CURVE_NURB_MAGIC, DB5_RAW_INTERNAL_MAGIC, DB_FULL_PATH_MAGIC, DBI_MAGIC, FB_MAGIC, LIGHT_MAGIC, MF_MAGIC, NMG_EDGE_G_CNURB_MAGIC, NMG_EDGE_G_LSEG_MAGIC, NMG_EDGE_MAGIC, NMG_EDGEUSE2_MAGIC, NMG_EDGEUSE_MAGIC, NMG_FACE_G_PLANE_MAGIC, NMG_FACE_G_SNURB_MAGIC, NMG_FACE_MAGIC, NMG_FACEUSE_MAGIC, NMG_KNOT_VECTOR_MAGIC, NMG_LOOP_G_MAGIC, NMG_LOOP_MAGIC, NMG_LOOPUSE_MAGIC, NMG_MODEL_MAGIC, NMG_RADIAL_MAGIC, NMG_RAY_DATA_MAGIC, NMG_REGION_A_MAGIC, NMG_REGION_MAGIC, NMG_RT_HIT_MAGIC, NMG_RT_HIT_SUB_MAGIC, NMG_RT_MISS_MAGIC, NMG_SHELL_A_MAGIC, NMG_SHELL_MAGIC, NMG_VERTEX_G_MAGIC, NMG_VERTEX_MAGIC, NMG_VERTEXUSE_A_CNURB_MAGIC, NMG_VERTEXUSE_A_PLANE_MAGIC, NMG_VERTEXUSE_MAGIC, PIXEL_EXT_MAGIC, PL_MAGIC, PT_HD_MAGIC, PT_MAGIC, RESOURCE_MAGIC, RT_ANP_MAGIC, RT_AP_MAGIC, RT_ARB_INTERNAL_MAGIC, RT_ARBN_INTERNAL_MAGIC, RT_ARS_INTERNAL_MAGIC, RT_BINUNIF_INTERNAL_MAGIC, RT_BOT_INTERNAL_MAGIC, RT_BREP_INTERNAL_MAGIC, RT_CLINE_INTERNAL_MAGIC, RT_COMB_MAGIC, RT_CONSTRAINT_MAGIC, RT_CTS_MAGIC, RT_DB_INTERNAL_MAGIC, RT_DB_TRAVERSE_MAGIC, RT_DBTS_MAGIC, RT_DIR_MAGIC, RT_DSP_INTERNAL_MAGIC, RT_EBM_INTERNAL_MAGIC, RT_EHY_INTERNAL_MAGIC, RT_ELL_INTERNAL_MAGIC, RT_EPA_INTERNAL_MAGIC, RT_ETO_INTERNAL_MAGIC, RT_EXTRUDE_INTERNAL_MAGIC, RT_FUNCTAB_MAGIC, RT_GRIP_INTERNAL_MAGIC, RT_HALF_INTERNAL_MAGIC, RT_HF_INTERNAL_MAGIC, RT_HIT_MAGIC, RT_HRT_INTERNAL_MAGIC, RT_HTBL_MAGIC, RT_METABALL_INTERNAL_MAGIC, RT_NURB_INTERNAL_MAGIC, RT_PART_INTERNAL_MAGIC, RT_PG_INTERNAL_MAGIC, RT_PIECELIST_MAGIC, RT_PIECESTATE_MAGIC, RT_PIPE_INTERNAL_MAGIC, RT_PNTS_INTERNAL_MAGIC, RT_RAY_MAGIC, RT_REGION_MAGIC, RT_REVOLVE_INTERNAL_MAGIC, RT_RHC_INTERNAL_MAGIC, RT_RPC_INTERNAL_MAGIC, RT_SEG_MAGIC, RT_SKETCH_INTERNAL_MAGIC, RT_SOLTAB2_MAGIC, RT_SOLTAB_MAGIC, RT_SUBMODEL_INTERNAL_MAGIC, RT_SUPERELL_INTERNAL_MAGIC, RT_TESS_TOL_MAGIC, RT_TGC_INTERNAL_MAGIC, RT_TOR_INTERNAL_MAGIC, RT_TREE_MAGIC, RT_VOL_INTERNAL_MAGIC, RT_WDB_MAGIC, RTI_MAGIC, VERT_TREE_MAGIC, WDB_METABALLPT_MAGIC, WDB_PIPESEG_MAGIC, and WMEMBER_MAGIC.