From 9634760d5eae4e8618e4b9ed9752d7305b3695a9 Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Tue, 27 Aug 2002 21:10:30 +0000 Subject: 17582: Improved option argument handling. unposted: Updated version to 4.1.0-dev-6 because of interface change. --- Src/Modules/zutil.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'Src/Modules/zutil.c') diff --git a/Src/Modules/zutil.c b/Src/Modules/zutil.c index cb099bbcc..4ef237d90 100644 --- a/Src/Modules/zutil.c +++ b/Src/Modules/zutil.c @@ -254,7 +254,7 @@ lookupstyle(char *ctxt, char *style) } static int -bin_zstyle(char *nam, char **args, char *ops, int func) +bin_zstyle(char *nam, char **args, Options ops, int func) { int min, max, n, add = 0, list = 0, eval = 0; @@ -550,7 +550,7 @@ bin_zstyle(char *nam, char **args, char *ops, int func) /* Format stuff. */ static int -bin_zformat(char *nam, char **args, char *ops, int func) +bin_zformat(char *nam, char **args, Options ops, int func) { char opt; @@ -1161,7 +1161,7 @@ rmatch(RParseResult *sm, char *subj, char *var1, char *var2, int comp) */ static int -bin_zregexparse(char *nam, char **args, char *ops, int func) +bin_zregexparse(char *nam, char **args, Options ops, int func) { int oldextendedglob = opts[EXTENDEDGLOB]; char *var1 = args[0]; @@ -1187,7 +1187,7 @@ bin_zregexparse(char *nam, char **args, char *ops, int func) ret = 0; if (!ret) - ret = rmatch(&result, subj, var1, var2, ops['c']); + ret = rmatch(&result, subj, var1, var2, OPT_ISSET(ops,'c')); popheap(); opts[EXTENDEDGLOB] = oldextendedglob; @@ -1315,7 +1315,7 @@ add_opt_val(Zoptdesc d, char *arg) } static int -bin_zparseopts(char *nam, char **args, char *ops, int func) +bin_zparseopts(char *nam, char **args, Options ops, int func) { char *o, *p, *n, **pp, **aval, **ap, *assoc = NULL, **cp, **np; int del = 0, f, extract = 0, keep = 0; -- cgit v1.2.3