From e75032ebe7b8f62e4cdfa82b5954259e436630af Mon Sep 17 00:00:00 2001 From: Jeroen Ruigrok/asmodai Date: Tue, 27 Jul 2004 11:22:34 +0000 Subject: [PATCH] Get rid of varargs.h. --- lib/libedit/el.c | 22 ++-------------------- lib/libedit/history.c | 19 +------------------ 2 files changed, 3 insertions(+), 38 deletions(-) diff --git a/lib/libedit/el.c b/lib/libedit/el.c index e107b2a15c..981a1ed55b 100644 --- a/lib/libedit/el.c +++ b/lib/libedit/el.c @@ -35,7 +35,7 @@ * * @(#)el.c 8.2 (Berkeley) 1/3/94 * $FreeBSD: src/lib/libedit/el.c,v 1.6.2.1 2000/05/22 06:07:00 imp Exp $ - * $DragonFly: src/lib/libedit/el.c,v 1.2 2003/06/17 04:26:49 dillon Exp $ + * $DragonFly: src/lib/libedit/el.c,v 1.3 2004/07/27 11:22:34 asmodai Exp $ */ /* @@ -48,11 +48,7 @@ #include #include #include -#if __STDC__ -# include -#else -# include -#endif +#include #include "el.h" /* el_init(): @@ -152,25 +148,11 @@ el_reset(el) * set the editline parameters */ public int -#if __STDC__ el_set(EditLine *el, int op, ...) -#else -el_set(va_alist) - va_dcl -#endif { va_list va; int rv; -#if __STDC__ va_start(va, op); -#else - EditLine *el; - int op; - - va_start(va); - el = va_arg(va, EditLine *); - op = va_arg(va, int); -#endif switch (op) { case EL_PROMPT: diff --git a/lib/libedit/history.c b/lib/libedit/history.c index 3e0ac8ca48..ccf09fb3ea 100644 --- a/lib/libedit/history.c +++ b/lib/libedit/history.c @@ -34,7 +34,7 @@ * SUCH DAMAGE. * * @(#)history.c 8.1 (Berkeley) 6/4/93 - * $DragonFly: src/lib/libedit/history.c,v 1.4 2003/11/12 20:21:29 eirikn Exp $ + * $DragonFly: src/lib/libedit/history.c,v 1.5 2004/07/27 11:22:34 asmodai Exp $ */ /* @@ -44,11 +44,7 @@ #include #include -#if __STDC__ #include -#else -#include -#endif static const char hist_cookie[] = "_HiStOrY_V1_\n"; @@ -562,27 +558,14 @@ history_next_string(h, str) * User interface to history functions. */ const HistEvent * -#if __STDC__ history(History *h, int fun, ...) -#else -history(va_alist) - va_dcl -#endif { va_list va; const HistEvent *ev = NULL; const char *str; static HistEvent sev = { 0, "" }; -#if __STDC__ va_start(va, fun); -#else - History *h; - int fun; - va_start(va); - h = va_arg(va, History *); - fun = va_arg(va, int); -#endif switch (fun) { case H_ADD: -- 2.41.0