Commit f9fd5d9d authored by Yukihiro "Matz" Matsumoto's avatar Yukihiro "Matz" Matsumoto

Merge pull request #965 from cremno/mrbc-multiple-outfiles-mem-leak

mrbc: exit if "-o" is specified multiple times
parents cdd41a33 245c095d
......@@ -83,6 +83,12 @@ parse_args(mrb_state *mrb, int argc, char **argv, struct _args *args)
switch ((*argv)[1]) {
case 'o':
if (outfile) {
printf("%s: An output file is already specified. (%s)\n",
*origargv, outfile);
result = -5;
goto exit;
}
outfile = get_outfilename((*argv) + 2, "");
break;
case 'B':
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment