• Luiz Capitulino's avatar
    [PATCH] PCI: fix pci/probe.c possible NULL pointer. · 0abcbadd
    Luiz Capitulino authored
     In drivers/pci/probe.c::pci_scan_bridge() the call for pci_alloc_child_bus()
    can return NULL, but it is not handled by the function (detected by
    Coverity's checker).
    
     The patch bellow fix that returning `max' if we got the NULL, but
    I do not know if it is right. I guess it is, because in that case
    the function will act in the same way as with `pass != 0'.
    
    Signed-off by: Luiz Capitulino <lcapitulino@prefeitura.sp.gov.br>
    Signed-off-by: default avatarGreg Kroah-Hartman <greg@kroah.com>
    0abcbadd
probe.c 21.1 KB