dos33: fix segfault when loading from disk image

probably broke this in recent file cleanups :(
This commit is contained in:
Vince Weaver 2017-01-09 11:41:12 -05:00
parent e3d5d1e525
commit 1c021fa1b1
1 changed files with 5 additions and 1 deletions

View File

@ -1398,10 +1398,14 @@ int main(int argc, char **argv) {
/* get output filename */
optind++;
if (argc>=optind) {
if (argc>optind) {
if (debug) printf("Using %s for filename\n",
local_filename);
strncpy(local_filename,argv[optind],BUFSIZ);
}
else {
if (debug) printf("Using %s for filename\n",
apple_filename);
strncpy(local_filename,apple_filename,30);
}