summaryrefslogtreecommitdiffstats
path: root/bin/ksh/edit.c
diff options
context:
space:
mode:
authormillert <millert@openbsd.org>2017-12-27 13:02:57 +0000
committermillert <millert@openbsd.org>2017-12-27 13:02:57 +0000
commit201e0776e68df3547d24a3790d166bbefd438756 (patch)
tree6641963dd6823f21f53451d5686cd4996555f12a /bin/ksh/edit.c
parentImplement OF_getpropint64(). (diff)
downloadwireguard-openbsd-201e0776e68df3547d24a3790d166bbefd438756.tar.xz
wireguard-openbsd-201e0776e68df3547d24a3790d166bbefd438756.zip
Add -Wshadow to Makefile and fix the resulting warnings. Many of
the warnings are due to the use of globals with generic names, specifically "options" and "path". I've renamed "options" to "sh_options" since it holds the shell options and "path" to "search_path". OK jca@ tb@
Diffstat (limited to 'bin/ksh/edit.c')
-rw-r--r--bin/ksh/edit.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/ksh/edit.c b/bin/ksh/edit.c
index fb85f9ff7f0..115091b179f 100644
--- a/bin/ksh/edit.c
+++ b/bin/ksh/edit.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: edit.c,v 1.57 2016/09/08 12:12:40 nicm Exp $ */
+/* $OpenBSD: edit.c,v 1.58 2017/12/27 13:02:57 millert Exp $ */
/*
* Command line editing - common code
@@ -229,7 +229,7 @@ set_editmode(const char *ed)
if ((rcp = strrchr(ed, '/')))
ed = ++rcp;
for (i = 0; i < NELEM(edit_flags); i++)
- if (strstr(ed, options[(int) edit_flags[i]].name)) {
+ if (strstr(ed, sh_options[(int) edit_flags[i]].name)) {
change_flag(edit_flags[i], OF_SPECIAL, 1);
return;
}
@@ -459,7 +459,7 @@ x_command_glob(int flags, const char *str, int slen, char ***wordsp)
for (l = genv->loc; l; l = l->next)
glob_table(pat, &w, &l->funs);
- glob_path(flags, pat, &w, path);
+ glob_path(flags, pat, &w, search_path);
if ((fpath = str_val(global("FPATH"))) != null)
glob_path(flags, pat, &w, fpath);