diff options
author | Thomas White <taw@physics.org> | 2022-06-02 14:58:29 +0200 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2022-06-02 15:25:20 +0200 |
commit | d228555f873967801633d02cdb55bae9dbdf9bfc (patch) | |
tree | 789bc9962f43187e656c0bee9518a07c11bcb619 /src/indexamajig.c | |
parent | e03c209ae05aefa0f46bc3897c31898be05fc767 (diff) |
indexamajig: Make all three input options mutually exclusive
Diffstat (limited to 'src/indexamajig.c')
-rw-r--r-- | src/indexamajig.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/indexamajig.c b/src/indexamajig.c index 6787f903..b31d2e10 100644 --- a/src/indexamajig.c +++ b/src/indexamajig.c @@ -1110,7 +1110,20 @@ int main(int argc, char *argv[]) } if ( (args.filename != NULL) && (args.zmq_addr != NULL) ) { - ERROR("You must only specify one of --input and --zmq-input.\n"); + ERROR("The options --input and --zmq-input are mutually " + "exclusive.\n"); + return 1; + } + + if ( (args.filename != NULL) && (args.asapo_endpoint != NULL) ) { + ERROR("The options --input and --asapo-endpoint are mutually " + "exclusive.\n"); + return 1; + } + + if ( (args.asapo_endpoint != NULL) && (args.zmq_addr != NULL) ) { + ERROR("The options --asapo-endpoint and --zmq-input are mutually " + "exclusive.\n"); return 1; } |