aboutsummaryrefslogtreecommitdiff
path: root/libcrystfel/src/reax.c
diff options
context:
space:
mode:
authorThomas White <taw@bitwiz.org.uk>2012-08-08 11:59:46 +0200
committerThomas White <taw@bitwiz.org.uk>2012-08-08 11:59:46 +0200
commite295e00053fff65f53e45ebb6b149d65225d04a8 (patch)
tree47e6bd3264bff5d592e281b7019c5b284a3a64bf /libcrystfel/src/reax.c
parent7903f6c31f7a13c26d97bdf1f7791c5b5804ea84 (diff)
Fix buglets spotted by new compiler on Fedora 17
Diffstat (limited to 'libcrystfel/src/reax.c')
-rw-r--r--libcrystfel/src/reax.c15
1 files changed, 4 insertions, 11 deletions
diff --git a/libcrystfel/src/reax.c b/libcrystfel/src/reax.c
index 259ec199..5cfa908a 100644
--- a/libcrystfel/src/reax.c
+++ b/libcrystfel/src/reax.c
@@ -467,7 +467,6 @@ static void find_candidates(struct reax_private *p,
const char *rg, struct detector *det)
{
int i;
- double th, ph;
for ( i=0; i<s->n_search; i++ ) {
s->search[i].cand = calloc(MAX_CANDIDATES,
@@ -475,7 +474,6 @@ static void find_candidates(struct reax_private *p,
s->search[i].n_cand = 0;
}
- th = 0.0; ph = 0.0;
for ( i=0; i<p->n_dir; i++ ) {
check_dir(&p->directions[i], flist,
p->nel, pmax, fft_in, fft_out, p->plan,
@@ -492,7 +490,10 @@ static void find_candidates(struct reax_private *p,
int j;
sv = &s->search[i];
- refine_vector(flist, &sv->cand[j].v);
+
+ for ( j=0; j<sv->n_cand; j++ ) {
+ refine_vector(flist, &sv->cand[j].v);
+ }
}
@@ -593,7 +594,6 @@ static void refine_rigid_group(struct image *image, UnitCell *cell,
double bx, by, bz, mb;
double cx, cy, cz, mc;
double pha, phb, phc;
- struct panel *p;
int i, j;
fftw_complex *r_fft_in;
fftw_complex *r_fft_out;
@@ -618,13 +618,6 @@ static void refine_rigid_group(struct image *image, UnitCell *cell,
pr->nel, pmax, fft_in, fft_out, plan,
smin, smax, rg, det);
- for ( i=0; i<det->n_panels; i++ ) {
- if ( det->panels[i].rigid_group == rg ) {
- p = &det->panels[i];
- break;
- }
- }
-
r_fft_in = fftw_malloc(pr->cw*pr->ch*sizeof(fftw_complex));
r_fft_out = fftw_malloc(pr->cw*pr->ch*sizeof(fftw_complex));
for ( i=0; i<pr->cw; i++ ) {