|
|
| version 1.3, 2003/11/17 13:17:16 | version 1.4, 2003/11/17 16:10:43 |
|---|---|
| Line 31 dosio_term(void) | Line 31 dosio_term(void) |
| FILEH | FILEH |
| file_open(const char *path) | file_open(const char *path) |
| { | { |
| FILEH fh; | |
| return fopen(path, "rb+"); | fh = fopen(path, "rb+"); |
| if (fh) | |
| return fh; | |
| return fopen(path, "rb"); | |
| } | } |
| FILEH | FILEH |
| file_open_rb(const char *path) | file_open_rb(const char *path) |
| { | { |
| FILEH fh; | |
| return fopen(path, "rb+"); | fh = fopen(path, "rb+"); |
| if (fh) | |
| return fh; | |
| return fopen(path, "rb"); | |
| } | } |
| FILEH | FILEH |
| Line 233 file_cpyname(char *dst, const char *src, | Line 241 file_cpyname(char *dst, const char *src, |
| for (i = 0; i < maxlen && src[i] != '\0'; i++) { | for (i = 0; i < maxlen && src[i] != '\0'; i++) { |
| dst[i] = src[i]; | dst[i] = src[i]; |
| } | } |
| if (i != 0) { | if (i > 0) { |
| if (euckanji1st(src, i-1)) { | if (euckanji1st(src, i-1)) { |
| i--; | i--; |
| } | } |