diff options
author | Thomas White <taw@bitwiz.org.uk> | 2010-06-11 15:42:45 -0700 |
---|---|---|
committer | Thomas White <taw@bitwiz.org.uk> | 2010-06-11 15:44:16 -0700 |
commit | 0559d06f61cd3f30b5925fe062654eca83eb6dd6 (patch) | |
tree | 7c4d588b4827ddeede470b405c3ea511f3a8bfd2 /src/pattern_sim.c | |
parent | e5adbd4bdf620467c44a7ad99a366e39f04578a2 (diff) |
Tidy up switch statements
Diffstat (limited to 'src/pattern_sim.c')
-rw-r--r-- | src/pattern_sim.c | 33 |
1 files changed, 11 insertions, 22 deletions
diff --git a/src/pattern_sim.c b/src/pattern_sim.c index 44963b9d..1f12caa2 100644 --- a/src/pattern_sim.c +++ b/src/pattern_sim.c @@ -222,59 +222,48 @@ int main(int argc, char *argv[]) longopts, NULL)) != -1) { switch (c) { - case 'h' : { + case 'h' : show_help(argv[0]); return 0; - } - case 'r' : { + case 'r' : config_randomquat = 1; break; - } - case 'n' : { + case 'n' : n_images = atoi(optarg); break; - } - case 'i' : { + case 'i' : intfile = strdup(optarg); break; - } - case 't' : { + case 't' : grad_str = strdup(optarg); break; - } - case 'p' : { + case 'p' : filename = strdup(optarg); break; - } - case 'o' : { + case 'o' : outfile = strdup(optarg); break; - } - case 'w' : { + case 'w' : powder_fn = strdup(optarg); break; - } - case 'g' : { + case 'g' : geometry = strdup(optarg); break; - } - case 0 : { + case 0 : break; - } - default : { + default : return 1; } - } } |