diff --git a/ChangeLog b/ChangeLog index 32a2a8e2a..41a941cb7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2013-04-29 Vladimir Serbinenko + + * grub-core/lib/arg.c (grub_arg_show_help): Fix a NULL pointer + dereference. + Reported by: qwertial. + 2013-04-28 Vladimir Serbinenko * docs/grub.texi: Add a comment about usefullness of nativedisk. diff --git a/grub-core/lib/arg.c b/grub-core/lib/arg.c index 7492ac6a8..9cc18dc2e 100644 --- a/grub-core/lib/arg.c +++ b/grub-core/lib/arg.c @@ -158,7 +158,7 @@ grub_arg_show_help (grub_extcmd_t cmd) show_usage (cmd); grub_printf ("%s\n\n", _(cmd->cmd->description)); - for (opt = cmd->options; opt->doc; opt++) + for (opt = cmd->options; opt && opt->doc; opt++) switch (opt->shortarg) { case 'h':