summaryrefslogtreecommitdiffhomepage
path: root/src/driver
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2015-12-23 06:02:16 -0500
committermidipix <writeonce@midipix.org>2016-11-11 00:22:31 -0500
commit57f0fbfe5e6b2fc8d516f147f1e39dc8a8d94062 (patch)
tree748b728fd0a71c38869db349394fdacacc108549 /src/driver
parentf455847564c7cb6a7a95c451351cd0ff2adb8a31 (diff)
downloadmdso-57f0fbfe5e6b2fc8d516f147f1e39dc8a8d94062.tar.bz2
mdso-57f0fbfe5e6b2fc8d516f147f1e39dc8a8d94062.tar.xz
driver: show usage information if no other action needs to be taken.
Diffstat (limited to 'src/driver')
-rw-r--r--src/driver/mdso_driver_ctx.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/driver/mdso_driver_ctx.c b/src/driver/mdso_driver_ctx.c
index 61cd77f..1538d95 100644
--- a/src/driver/mdso_driver_ctx.c
+++ b/src/driver/mdso_driver_ctx.c
@@ -207,6 +207,9 @@ int mdso_get_driver_ctx(
nunits++;
}
+ if (!nunits && !(cctx.drvflags & MDSO_DRIVER_VERSION))
+ return mdso_driver_usage(program,0,options,meta);
+
if (pretty && !strcmp(pretty,"yaml"))
cctx.fmtflags |= MDSO_PRETTY_YAML;