diff options
author | andmarti1424 <andmarti@gmail.com> | 2017-05-11 20:46:00 -0300 |
---|---|---|
committer | andmarti1424 <andmarti@gmail.com> | 2017-05-11 20:46:00 -0300 |
commit | 43abb1b0542a9890d2a0efe41a867dfaf35d2456 (patch) | |
tree | 4887eab976e2eb89386d32ee7098b94ca4cc2f02 /src/file.c | |
parent | 7db4b5124f271d7a0b122c101476c7bcdac94934 (diff) |
readfile: set curfile even if sc file tried to read does not exists
Diffstat (limited to 'src/file.c')
-rwxr-xr-x | src/file.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -571,7 +571,7 @@ int readfile(char * fname, int eraseflg) { } // We open an 'sc' format file - // open fname for reading ? + // open fname for reading register FILE * f; char save[PATHLEN]; if (*fname == '\0') fname = curfile; @@ -579,6 +579,7 @@ int readfile(char * fname, int eraseflg) { f = fopen(save, "r"); if (f == NULL) { loading = 0; + strcpy(curfile, save); return 0; } /* */ |