man: fix segfault in "man 1"
function old new delta man_main 942 954 +12 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
parent
e47000490c
commit
4d4fc5ca5e
@ -324,7 +324,7 @@ int man_main(int argc UNUSED_PARAM, char **argv)
|
|||||||
|
|
||||||
/* is 1st ARG a SECTION? */
|
/* is 1st ARG a SECTION? */
|
||||||
sec_list = conf_sec_list;
|
sec_list = conf_sec_list;
|
||||||
if (is_section_name(conf_sec_list, *argv)) {
|
if (is_section_name(conf_sec_list, *argv) && argv[1]) {
|
||||||
/* yes */
|
/* yes */
|
||||||
sec_list = *argv++;
|
sec_list = *argv++;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user