Fix assert failure when opening with no args
This commit is contained in:
parent
14a80dbabd
commit
a315ce6903
1 changed files with 2 additions and 1 deletions
|
@ -318,7 +318,8 @@ bool AegisubApp::OnInit() {
|
||||||
// Get parameter subs
|
// Get parameter subs
|
||||||
StartupLog("Parse command line");
|
StartupLog("Parse command line");
|
||||||
auto const& args = argv.GetArguments();
|
auto const& args = argv.GetArguments();
|
||||||
OpenFiles(wxArrayStringsAdapter(args.size() - 1, &args[1]));
|
if (args.size() > 1)
|
||||||
|
OpenFiles(wxArrayStringsAdapter(args.size() - 1, &args[1]));
|
||||||
}
|
}
|
||||||
catch (agi::Exception const& e) {
|
catch (agi::Exception const& e) {
|
||||||
wxMessageBox(to_wx(e.GetMessage()), "Fatal error while initializing");
|
wxMessageBox(to_wx(e.GetMessage()), "Fatal error while initializing");
|
||||||
|
|
Loading…
Reference in a new issue