[lkml]   [2008]   [Dec]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    Patch in this message
    Subject[patch 72/83] PCI: stop leaking slot_name in pci_create_slot
    2.6.27-stable review patch.  If anyone has any objections, please let us know.


    From: Alex Chiang <>

    commit 3b5dd45e947ecd21491e1658fba7bb4bc4a54995 upstream.

    In pci_create_slot(), the local variable 'slot_name' is allocated by
    make_slot_name(), but never freed. We never use it after passing it to
    the kobject core, so we should free it upon function exit.

    Signed-off-by: Alex Chiang <>
    Signed-off-by: Jesse Barnes <>
    Signed-off-by: Greg Kroah-Hartman <>

    drivers/pci/slot.c | 1 +
    1 file changed, 1 insertion(+)

    --- a/drivers/pci/slot.c
    +++ b/drivers/pci/slot.c
    @@ -243,6 +243,7 @@ placeholder:
    __func__, pci_domain_nr(parent), parent->number, slot_nr);

    + kfree(slot_name);
    return slot;

     \ /
      Last update: 2008-12-11 20:47    [W:0.021 / U:9.536 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site