From 3b409a8e299446e3118743ff2508c54330011eeb Mon Sep 17 00:00:00 2001 From: Vegard Nossum Date: Wed, 13 Jun 2018 12:38:53 +0200 Subject: [PATCH] pppd: Fix printing call in print_option() print_option() was in this case passing p/opt->addr2 as the format string instead of the string to be printed (as a quoted string). That could lead to a nasty crash. Signed-off-by: Vegard Nossum Signed-off-by: Paul Mackerras --- pppd/options.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pppd/options.c b/pppd/options.c index 6e38d43..482dce6 100644 --- a/pppd/options.c +++ b/pppd/options.c @@ -992,7 +992,7 @@ print_option(opt, mainopt, printer, arg) p = (char *) opt->addr2; if ((opt->flags & OPT_STATIC) == 0) p = *(char **)p; - printer("%q", p); + printer(arg, "%q", p); } else if (opt->flags & OPT_A2LIST) { struct option_value *ovp; -- 2.39.2