From f8b0dee88051065d4667fe41dd1bc81905c2b07c Mon Sep 17 00:00:00 2001 From: Tanaka Akira Date: Wed, 24 Nov 1999 16:20:58 +0000 Subject: zsh-workers/8770 --- Src/Zle/compctl.c | 4 ---- Src/Zle/complete.c | 7 ++----- Src/Zle/complist.c | 4 ---- Src/Zle/computil.c | 4 ---- Src/Zle/deltochar.c | 4 ---- Src/Zle/zle_hist.c | 6 ------ Src/Zle/zle_keymap.c | 4 ---- Src/Zle/zle_main.c | 4 ---- Src/Zle/zle_thingy.c | 12 ------------ Src/Zle/zleparameter.c | 4 ---- 10 files changed, 2 insertions(+), 51 deletions(-) (limited to 'Src/Zle') diff --git a/Src/Zle/compctl.c b/Src/Zle/compctl.c index cab0f55a4..cb8f32a3a 100644 --- a/Src/Zle/compctl.c +++ b/Src/Zle/compctl.c @@ -3764,8 +3764,6 @@ boot_compctl(Module m) return (addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab)) != 1); } -#ifdef MODULE - /**/ int cleanup_compctl(Module m) @@ -3789,5 +3787,3 @@ finish_compctl(Module m) compctlreadptr = fallback_compctlread; return 0; } - -#endif diff --git a/Src/Zle/complete.c b/Src/Zle/complete.c index bf558f352..f52ac98ef 100644 --- a/Src/Zle/complete.c +++ b/Src/Zle/complete.c @@ -1389,8 +1389,6 @@ boot_complete(Module m) return 0; } -#ifdef MODULE - /**/ int cleanup_complete(Module m) @@ -1414,7 +1412,8 @@ cleanup_complete(Module m) int finish_complete(Module m) { - freearray(compwords); + if (compwords) + freearray(compwords); zsfree(compprefix); zsfree(compsuffix); zsfree(compiprefix); @@ -1446,5 +1445,3 @@ finish_complete(Module m) return 0; } - -#endif diff --git a/Src/Zle/complist.c b/Src/Zle/complist.c index 5f40ffb9a..612191913 100644 --- a/Src/Zle/complist.c +++ b/Src/Zle/complist.c @@ -935,8 +935,6 @@ boot_complist(Module m) return 0; } -#ifdef MODULE - /**/ int cleanup_complist(Module m) @@ -957,5 +955,3 @@ finish_complist(Module m) { return 0; } - -#endif diff --git a/Src/Zle/computil.c b/Src/Zle/computil.c index fd39e255b..f39a65b48 100644 --- a/Src/Zle/computil.c +++ b/Src/Zle/computil.c @@ -2837,8 +2837,6 @@ boot_computil(Module m) return !addbuiltins(m->nam, bintab, sizeof(bintab)/sizeof(*bintab)); } -#ifdef MODULE - /**/ int cleanup_computil(Module m) @@ -2865,5 +2863,3 @@ finish_computil(Module m) return 0; } - -#endif diff --git a/Src/Zle/deltochar.c b/Src/Zle/deltochar.c index 566a578f1..e3f9def0c 100644 --- a/Src/Zle/deltochar.c +++ b/Src/Zle/deltochar.c @@ -98,8 +98,6 @@ boot_deltochar(Module m) return -1; } -#ifdef MODULE - /**/ int cleanup_deltochar(Module m) @@ -115,5 +113,3 @@ finish_deltochar(Module m) { return 0; } - -#endif diff --git a/Src/Zle/zle_hist.c b/Src/Zle/zle_hist.c index f85fa00a6..d6dc2a794 100644 --- a/Src/Zle/zle_hist.c +++ b/Src/Zle/zle_hist.c @@ -611,9 +611,6 @@ static struct isrch_spot { static int max_spot = 0; -/**/ -#ifdef MODULE - /**/ void free_isrch_spots(void) @@ -621,9 +618,6 @@ free_isrch_spots(void) zfree(isrch_spots, max_spot * sizeof(*isrch_spots)); } -/**/ -#endif /* MODULE */ - /**/ static void set_isrch_spot(int num, int hl, int pos, int cs, int len, int dir, int nomatch) diff --git a/Src/Zle/zle_keymap.c b/Src/Zle/zle_keymap.c index 37c32d581..ccfbd4043 100644 --- a/Src/Zle/zle_keymap.c +++ b/Src/Zle/zle_keymap.c @@ -1000,8 +1000,6 @@ init_keymaps(void) lastnamed = refthingy(t_undefinedkey); } -#ifdef MODULE - /* cleanup entry point (for unloading the zle module) */ /**/ @@ -1013,8 +1011,6 @@ cleanup_keymaps(void) zfree(keybuf, keybufsz); } -#endif /* MODULE */ - /* Create the default keymaps. For efficiency reasons, this function * * assigns directly to the km->first array. It knows that there are no * * prefix bindings in the way, and that it is using a simple keymap. */ diff --git a/Src/Zle/zle_main.c b/Src/Zle/zle_main.c index 42b4e21e4..4f5729818 100644 --- a/Src/Zle/zle_main.c +++ b/Src/Zle/zle_main.c @@ -1043,8 +1043,6 @@ boot_zle(Module m) return 0; } -#ifdef MODULE - /**/ int cleanup_zle(Module m) @@ -1093,5 +1091,3 @@ finish_zle(Module m) return 0; } - -#endif /* MODULE */ diff --git a/Src/Zle/zle_thingy.c b/Src/Zle/zle_thingy.c index a4191a9a4..1e0d483e2 100644 --- a/Src/Zle/zle_thingy.c +++ b/Src/Zle/zle_thingy.c @@ -286,8 +286,6 @@ addzlefunction(char *name, ZleIntFunc ifunc, int flags) return w; } -#ifdef DYNAMIC - /* Delete an internal widget provided by a module. Don't try to delete * * a widget from the fixed table -- it would be bad. (Thanks, Egon.) */ @@ -309,8 +307,6 @@ deletezlefunction(Widget w) } } -#endif /* DYNAMIC */ - /***************/ /* zle builtin */ /***************/ @@ -550,18 +546,10 @@ bin_zle_complete(char *name, char **args, char *ops, char func) Thingy t; Widget w, cw; -#ifdef DYNAMIC if (!require_module(name, "complete", 0, 0)) { zerrnam(name, "can't load complete module", NULL, 0); return 1; } -#else - if (!module_linked("complete")) { - zerrnam(name, "complete module not available", NULL, 0); - return 1; - } -#endif - t = rthingy((args[1][0] == '.') ? args[1] : dyncat(".", args[1])); cw = t->widget; unrefthingy(t); diff --git a/Src/Zle/zleparameter.c b/Src/Zle/zleparameter.c index 9103916bb..c4347de6b 100644 --- a/Src/Zle/zleparameter.c +++ b/Src/Zle/zleparameter.c @@ -230,8 +230,6 @@ boot_zleparameter(Module m) return 0; } -#ifdef MODULE - /**/ int cleanup_zleparameter(Module m) @@ -255,5 +253,3 @@ finish_zleparameter(Module m) { return 0; } - -#endif -- cgit 1.4.1