From bc5a0359e04a4a4f2070ef183aededc20dc6b9da Mon Sep 17 00:00:00 2001 From: Thomas White Date: Thu, 1 Jul 2010 15:41:02 +0200 Subject: Trap on invalid weighting --- src/render_hkl.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/render_hkl.c') diff --git a/src/render_hkl.c b/src/render_hkl.c index 46ba4c89..d7a9069e 100644 --- a/src/render_hkl.c +++ b/src/render_hkl.c @@ -135,6 +135,9 @@ static void render_za(UnitCell *cell, double *ref, unsigned int *c, case WGHT_RAWCOUNTS : val = (float)ct; break; + default : + ERROR("Invalid weighting.\n"); + abort(); } nequiv = num_equivs(h, k, 0, sym); @@ -204,6 +207,9 @@ static void render_za(UnitCell *cell, double *ref, unsigned int *c, case WGHT_RAWCOUNTS : val = (float)ct; break; + default : + ERROR("Invalid weighting.\n"); + abort(); } val = boost*val/max_val; -- cgit v1.2.3