summaryrefslogtreecommitdiff
path: root/editors/vi.c
diff options
context:
space:
mode:
Diffstat (limited to 'editors/vi.c')
-rw-r--r--editors/vi.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/editors/vi.c b/editors/vi.c
index cda17db..144e9d7 100644
--- a/editors/vi.c
+++ b/editors/vi.c
@@ -19,7 +19,7 @@
*/
static const char vi_Version[] =
- "$Id: vi.c,v 1.27 2002/12/03 21:48:15 bug1 Exp $";
+ "$Id: vi.c,v 1.28 2003/03/19 09:11:45 mjn3 Exp $";
/*
* To compile for standalone use:
@@ -403,7 +403,7 @@ extern int vi_main(int argc, char **argv)
for (; optind < argc; optind++) {
editing = 1; // 0=exit, 1=one file, 2+ =many files
free(cfn);
- cfn = (Byte *) xstrdup(argv[optind]);
+ cfn = (Byte *) bb_xstrdup(argv[optind]);
edit_file(cfn);
}
}
@@ -597,7 +597,7 @@ static Byte *get_one_address(Byte * p, int *addr) // get colon addr, if present
*q++ = *p;
*q = '\0';
}
- pat = (Byte *) xstrdup((char *) buf); // save copy of pattern
+ pat = (Byte *) bb_xstrdup((char *) buf); // save copy of pattern
if (*p == '/')
p++;
q = char_search(dot, pat, FORWARD, FULL);
@@ -811,7 +811,7 @@ static void colon(Byte * buf)
// There is a read-able regular file
// make this the current file
- q = (Byte *) xstrdup((char *) fn); // save the cfn
+ q = (Byte *) bb_xstrdup((char *) fn); // save the cfn
free(cfn); // free the old name
cfn = q; // remember new cfn
@@ -862,7 +862,7 @@ static void colon(Byte * buf)
if (strlen((char *) args) > 0) {
// user wants a new filename
free(cfn);
- cfn = (Byte *) xstrdup((char *) args);
+ cfn = (Byte *) bb_xstrdup((char *) args);
} else {
// user wants file status info
edit_status();
@@ -2432,7 +2432,7 @@ static Byte *get_input_line(Byte * prompt) // get input line- use "status line"
}
refresh(FALSE);
free(obufp);
- obufp = (Byte *) xstrdup((char *) buf);
+ obufp = (Byte *) bb_xstrdup((char *) buf);
return (obufp);
}
@@ -3263,7 +3263,7 @@ key_cmd_mode:
// Stuff the last_modifying_cmd back into stdin
// and let it be re-executed.
if (last_modifying_cmd != 0) {
- ioq = ioq_start = (Byte *) xstrdup((char *) last_modifying_cmd);
+ ioq = ioq_start = (Byte *) bb_xstrdup((char *) last_modifying_cmd);
}
break;
#endif /* CONFIG_FEATURE_VI_DOT_CMD */
@@ -3278,7 +3278,7 @@ key_cmd_mode:
if (strlen((char *) q) > 1) { // new pat- save it and find
// there is a new pat
free(last_search_pattern);
- last_search_pattern = (Byte *) xstrdup((char *) q);
+ last_search_pattern = (Byte *) bb_xstrdup((char *) q);
goto dc3; // now find the pattern
}
// user changed mind and erased the "/"- do nothing