diff options
Diffstat (limited to 'editors')
-rw-r--r-- | editors/vi.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/editors/vi.c b/editors/vi.c index fa30cf29c..a25e96657 100644 --- a/editors/vi.c +++ b/editors/vi.c | |||
@@ -2353,7 +2353,7 @@ static int file_insert(Byte * fn, Byte * p, int size) | |||
2353 | #endif | 2353 | #endif |
2354 | fd = open((char *) fn, O_RDONLY); // try read-only | 2354 | fd = open((char *) fn, O_RDONLY); // try read-only |
2355 | if (fd < 0) { | 2355 | if (fd < 0) { |
2356 | psbs("\"%s\" %s", fn, "could not open file"); | 2356 | psbs("\"%s\" %s", fn, "cannot open file"); |
2357 | goto fi0; | 2357 | goto fi0; |
2358 | } | 2358 | } |
2359 | #ifdef CONFIG_FEATURE_VI_READONLY | 2359 | #ifdef CONFIG_FEATURE_VI_READONLY |
@@ -2367,11 +2367,11 @@ static int file_insert(Byte * fn, Byte * p, int size) | |||
2367 | if (cnt < 0) { | 2367 | if (cnt < 0) { |
2368 | cnt = -1; | 2368 | cnt = -1; |
2369 | p = text_hole_delete(p, p + size - 1); // un-do buffer insert | 2369 | p = text_hole_delete(p, p + size - 1); // un-do buffer insert |
2370 | psbs("could not read file \"%s\"", fn); | 2370 | psbs("cannot read file \"%s\"", fn); |
2371 | } else if (cnt < size) { | 2371 | } else if (cnt < size) { |
2372 | // There was a partial read, shrink unused space text[] | 2372 | // There was a partial read, shrink unused space text[] |
2373 | p = text_hole_delete(p + cnt, p + (size - cnt) - 1); // un-do buffer insert | 2373 | p = text_hole_delete(p + cnt, p + (size - cnt) - 1); // un-do buffer insert |
2374 | psbs("could not read all of file \"%s\"", fn); | 2374 | psbs("cannot read all of file \"%s\"", fn); |
2375 | } | 2375 | } |
2376 | if (cnt >= size) | 2376 | if (cnt >= size) |
2377 | file_modified++; | 2377 | file_modified++; |