lkml.org 
[lkml]   [2012]   [Feb]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    Subject[PATCH] IB: Don't return freed pointer from srpt_alloc_ioctx_ring()
    Signed-off-by: Jesper Juhl <jj@chaosbits.net>
    ---
    drivers/infiniband/ulp/srpt/ib_srpt.c | 1 +
    1 files changed, 1 insertions(+), 0 deletions(-)

    compile tested only.

    diff --git a/drivers/infiniband/ulp/srpt/ib_srpt.c b/drivers/infiniband/ulp/srpt/ib_srpt.c
    index cd5d05e..a59c685 100644
    --- a/drivers/infiniband/ulp/srpt/ib_srpt.c
    +++ b/drivers/infiniband/ulp/srpt/ib_srpt.c
    @@ -687,6 +687,7 @@ err:
    while (--i >= 0)
    srpt_free_ioctx(sdev, ring[i], dma_size, dir);
    kfree(ring);
    + ring = NULL;
    out:
    return ring;
    }
    --
    1.7.9

    --
    Jesper Juhl <jj@chaosbits.net> http://www.chaosbits.net/
    Don't top-post http://www.catb.org/jargon/html/T/top-post.html
    Plain text mails only, please.



    \
     
     \ /
      Last update: 2012-02-04 23:51    [W:0.019 / U:61.892 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site