From: Ben Pfaff Date: Sun, 31 Jul 2005 06:14:17 +0000 (+0000) Subject: (validate_function_args) Fix two msg() bugs found by -Wformat. X-Git-Tag: v0.4.0~9 X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c1e0ac4b743ba15ffbe32e1d95cc7b4b40b1eaa4;p=pspp-builds.git (validate_function_args) Fix two msg() bugs found by -Wformat. --- diff --git a/src/ChangeLog b/src/ChangeLog index 5b4aac61..38129a86 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,6 +1,11 @@ +Sat Jul 30 23:13:17 2005 Ben Pfaff + + * expressions/parse.c: (validate_function_args) Fix two msg() bugs + found by -Wformat. + Sat Jul 30 23:10:01 2005 Ben Pfaff - * epxressions/evaluate.c: (expr_debug_print_postfix) Don't pass + * expressions/evaluate.c: (expr_debug_print_postfix) Don't pass null pointer to printf for %.*s. Sat Jul 30 23:05:33 2005 Ben Pfaff diff --git a/src/expressions/parse.c b/src/expressions/parse.c index a7064e03..bc639cd8 100644 --- a/src/expressions/parse.c +++ b/src/expressions/parse.c @@ -1033,7 +1033,7 @@ validate_function_args (const struct operation *f, int arg_cnt, int min_valid) { assert ((f->flags & OPF_MIN_VALID) == 0); msg (SE, _("%s function does not accept a minimum valid " - "argument count.")); + "argument count."), f->prototype); return false; } else @@ -1042,7 +1042,7 @@ validate_function_args (const struct operation *f, int arg_cnt, int min_valid) if (array_arg_cnt < f->array_min_elems) { msg (SE, _("%s requires at least %d valid arguments in list."), - f->prototype); + f->prototype, f->array_min_elems); return false; } else if (min_valid > array_arg_cnt)