[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH 04/14] xen/char: console: Use const whenever we point to literal strings
Hi Jan, On 06/04/2021 09:10, Jan Beulich wrote: On 05.04.2021 17:57, Julien Grall wrote:--- a/xen/drivers/char/console.c +++ b/xen/drivers/char/console.c @@ -168,7 +168,7 @@ static int parse_guest_loglvl(const char *s); static char xenlog_val[LOGLVL_VAL_SZ]; static char xenlog_guest_val[LOGLVL_VAL_SZ];-static char *lvl2opt[] = { "none", "error", "warning", "info", "all" };+static const char *lvl2opt[] = { "none", "error", "warning", "info", "all" };If you add any const here, then I think you should go to full way and also add the second missing one. Then Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx> Arguably the array should also be local to xenlog_update_val(). I will look at it and send a new version. Cheers, -- Julien Grall
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |