diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/hdfsee.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/hdfsee.c b/src/hdfsee.c index 1ef21559..cc35b6e0 100644 --- a/src/hdfsee.c +++ b/src/hdfsee.c @@ -131,7 +131,8 @@ int main(int argc, char *argv[]) int n_rings = -1; int median_filter = 0; struct detector *det_geom = NULL; - struct beam_params beam; + struct beam_params cbeam; + struct beam_params *beam = NULL; /* Long options */ const struct option longopts[] = { @@ -153,8 +154,8 @@ int main(int argc, char *argv[]) }; /* Default beam parameters */ - beam.photon_energy = 0.0; - beam.photon_energy_from = NULL; + cbeam.photon_energy = 0.0; + cbeam.photon_energy_from = NULL; /* This isn't great, but necessary to make the command-line UI and file * formats consistent with the other programs, which all use the C @@ -212,12 +213,13 @@ int main(int argc, char *argv[]) break; case 'g' : - det_geom = get_detector_geometry(optarg, &beam); + det_geom = get_detector_geometry(optarg, &cbeam); if ( det_geom == NULL ) { ERROR("Failed to read detector geometry from '%s'\n", optarg); return 1; } + beam = &cbeam; break; case 2 : @@ -296,7 +298,7 @@ int main(int argc, char *argv[]) config_noisefilter, config_calibmode, colscale, element, - det_geom, &beam, + det_geom, beam, config_showrings, ring_radii, n_rings, |