aboutsummaryrefslogtreecommitdiff
path: root/src/casm.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/casm.c')
-rw-r--r--src/casm.c18
1 files changed, 17 insertions, 1 deletions
diff --git a/src/casm.c b/src/casm.c
index 866b32d..9e5c68e 100644
--- a/src/casm.c
+++ b/src/casm.c
@@ -511,7 +511,23 @@ static CommandStatus IMPORT(const char *label, int argc, char *argv[],
{
CMD_ARGC_CHECK(2);
- return LibLoad(argv[1], LibLoadAll, err, errsize) ? CMD_OK : CMD_FAILED;
+ if (argc == 3)
+ {
+ if (CompareString(argv[2], "labels"))
+ {
+ return LibLoad(argv[1], LibLoadLabels, err, errsize) ?
+ CMD_OK : CMD_FAILED;
+ }
+ else
+ {
+ snprintf(err, errsize, "%s: unknown argument %s", argv[0], argv[2]);
+ return CMD_FAILED;
+ }
+ }
+ else
+ {
+ return LibLoad(argv[1], LibLoadAll, err, errsize) ? CMD_OK : CMD_FAILED;
+ }
}