[brlcad-commits] SF.net SVN: brlcad:[54511] brlcad/trunk/src/util/bwthresh.c
Open Source Solid Modeling CAD
Brought to you by:
brlcad
From: <car...@us...> - 2013-02-28 18:46:41
|
Revision: 54511 http://brlcad.svn.sourceforge.net/brlcad/?rev=54511&view=rev Author: carlmoore Date: 2013-02-28 18:46:34 +0000 (Thu, 28 Feb 2013) Log Message: ----------- if i is 0, do we proceed in that && construct to use i-1 subscript? Modified Paths: -------------- brlcad/trunk/src/util/bwthresh.c Modified: brlcad/trunk/src/util/bwthresh.c =================================================================== --- brlcad/trunk/src/util/bwthresh.c 2013-02-28 18:35:59 UTC (rev 54510) +++ brlcad/trunk/src/util/bwthresh.c 2013-02-28 18:46:34 UTC (rev 54511) @@ -67,8 +67,10 @@ bu_exit(1, "bwthresh: Threshold[%d] value %d out of range. Need 0 <= value <= 255\n", i, thresh_val[i]); } - if ((i > 0) && (thresh_val[i] <= thresh_val[i - 1])) { - bu_exit(1, "bwthresh: Threshold values not strictly increasing\n"); + if (i > 0) { + if (thresh_val[i] <= thresh_val[i - 1]) { + bu_exit(1, "bwthresh: Threshold values not strictly increasing\n"); + } } bin_color[i] = 256 * i / nm_threshs; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |