summaryrefslogtreecommitdiff
path: root/src/Dalos-cli.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/Dalos-cli.cc')
-rw-r--r--src/Dalos-cli.cc7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/Dalos-cli.cc b/src/Dalos-cli.cc
index 89069bf..dd0a4a8 100644
--- a/src/Dalos-cli.cc
+++ b/src/Dalos-cli.cc
@@ -74,16 +74,14 @@ void MainTask::Do() {
IO<Input> file(new Input(argv[optind++]));
LuaExecFile luaExecFile(file);
luaExecFile.exec(luaMainTask);
- if (luaExecFile.gotError())
- return;
+ luaExecFile.throwError();
}
for (auto & exec : execs) {
todo = true;
LuaExecString luaExecString(exec);
luaExecString.exec(luaMainTask);
- if (luaExecString.gotError())
- return;
+ luaExecString.throwError();
}
if (!todo && !interactive)
@@ -105,5 +103,6 @@ void MainTask::Do() {
LuaExecString luaExecString(line_read);
luaExecString.exec(luaMainTask);
+ luaExecString.throwError();
}
}