224 |
|
static int |
225 |
|
norm_check(FVECT nv1, FVECT nv2) |
226 |
|
{ |
227 |
< |
double max2 = nv1[2]*nv1[2]; |
227 |
> |
double max2 = nv1[2]*nv2[2]; |
228 |
|
int imax = 2; |
229 |
|
int i = 2; |
230 |
|
/* identify largest component */ |
231 |
|
while (i--) { |
232 |
< |
double tm2 = nv1[i]*nv1[i]; |
232 |
> |
double tm2 = nv1[i]*nv2[i]; |
233 |
|
if (tm2 > max2) { |
234 |
|
imax = i; |
235 |
|
max2 = tm2; |
696 |
|
static char depthvar[] = DEPTHSTR; |
697 |
|
const char *drval; |
698 |
|
|
699 |
< |
depthvar[LDEPTHSTR] = '\0'; |
699 |
> |
depthvar[LDEPTHSTR-1] = '\0'; |
700 |
|
drval = (const char *)lu_find(htp, depthvar)->data; |
701 |
|
if (!drval) |
702 |
|
return(0); |