summaryrefslogtreecommitdiffhomepage
path: root/src/driver
diff options
context:
space:
mode:
Diffstat (limited to 'src/driver')
-rw-r--r--src/driver/slbt_amain.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/driver/slbt_amain.c b/src/driver/slbt_amain.c
index 1cc1c07..2359293 100644
--- a/src/driver/slbt_amain.c
+++ b/src/driver/slbt_amain.c
@@ -176,10 +176,11 @@ int slbt_main(char ** argv, char ** envp, const struct slbt_fd_ctx * fdctx)
return slbt_output_machine(dctx)
? SLBT_ERROR : SLBT_OK;
- /* --version is always the first action */
+ /* --version must be the first (and only) action */
if (dctx->cctx->drvflags & SLBT_DRIVER_VERSION)
- if ((slbt_version(dctx,fdout)) < 0)
- return slbt_exit(dctx,SLBT_ERROR);
+ return (slbt_version(dctx,fdout) < 0)
+ ? slbt_exit(dctx,SLBT_ERROR)
+ : slbt_exit(dctx,SLBT_OK);
slbt_perform_driver_actions(dctx);