aboutsummaryrefslogtreecommitdiff
path: root/src/pattern_sim.c
diff options
context:
space:
mode:
authorThomas White <taw@physics.org>2014-11-14 15:45:47 +0100
committerThomas White <taw@physics.org>2014-11-14 15:45:47 +0100
commitf98c55524c74647ac999746929b8206f1ab178c0 (patch)
tree2b8b49446a1aedd75385ae4d3ae9ce481aa0a063 /src/pattern_sim.c
parent4d885d3485cd16e838a397f8a2483fcc331c8c87 (diff)
Background need not be an integer
Diffstat (limited to 'src/pattern_sim.c')
-rw-r--r--src/pattern_sim.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/pattern_sim.c b/src/pattern_sim.c
index 41f136bb..af8fd4a4 100644
--- a/src/pattern_sim.c
+++ b/src/pattern_sim.c
@@ -262,7 +262,7 @@ int main(int argc, char *argv[])
SymOpList *sym;
int nsamples = 3;
gsl_rng *rng;
- int background = 0;
+ double background = 0.0;
char *template_file = NULL;
Stream *st = NULL;
int no_fringes = 0;
@@ -403,7 +403,7 @@ int main(int argc, char *argv[])
break;
case 5 :
- background = strtol(optarg, &rval, 10);
+ background = strtod(optarg, &rval);
if ( *rval != '\0' ) {
ERROR("Invalid background level.\n");
return 1;