From 02e81df39b63e5befde7896e2ea5a267dd749b46 Mon Sep 17 00:00:00 2001 From: Kevin Shanahan Date: Mon, 22 Apr 2013 18:20:02 +0930 Subject: [PATCH] qbsp: replace error enums in csg4.c Signed-off-by: Kevin Shanahan --- qbsp/csg4.c | 6 +++--- qbsp/globals.c | 2 -- qbsp/warnerr.h | 2 -- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/qbsp/csg4.c b/qbsp/csg4.c index 76ae2f91..1b24d71a 100644 --- a/qbsp/csg4.c +++ b/qbsp/csg4.c @@ -101,7 +101,7 @@ SplitFace(face_t *in, const plane_t *split, face_t **front, face_t **back) vec3_t mid; if (in->w.numpoints < 0) - Error(errFreedFace); + Error_("Attempting to split freed face"); /* Fast test */ dot = DotProduct(in->origin, split->normal) - split->dist; @@ -176,9 +176,9 @@ SplitFace(face_t *in, const plane_t *split, face_t **front, face_t **back) } if (newf->w.numpoints > MAXEDGES || new2->w.numpoints > MAXEDGES) - Error(errLowSplitPointCount); + Error_("Internal error: numpoints > MAXEDGES (%s)", __func__); - // free the original face now that it is represented by the fragments + /* free the original face now that it is represented by the fragments */ FreeMem(in, FACE, 1); } diff --git a/qbsp/globals.c b/qbsp/globals.c index 3154ecc2..d6798ce9 100644 --- a/qbsp/globals.c +++ b/qbsp/globals.c @@ -92,9 +92,7 @@ const char *rgszErrors[cErrors] = { "Found a non-canonical vector", "Normalization error in FindPlane (vector length %.4f)", - "Attempting to split freed face", - "Internal error: numpoints > MAXEDGES in SplitFace", "Failure reading from file", "Colinear edge", "Portal already included in AddPortalToNodes", diff --git a/qbsp/warnerr.h b/qbsp/warnerr.h index 901ac44a..a3f27538 100644 --- a/qbsp/warnerr.h +++ b/qbsp/warnerr.h @@ -62,8 +62,6 @@ enum { errDegenerateEdge, errNonCanonicalVector, errNormalization, - errFreedFace, - errLowSplitPointCount, // 30 errReadFailure, errColinearEdge, errPortalAlreadyAdded,