[lkml]   [2010]   [Nov]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [PATCH] Char: virtio_console, fix memory leak
    On Sat, 6 Nov 2010 07:36:50 pm Jiri Slaby wrote:
    > Stanse found that in init_vqs, memory is leaked under certain
    > circumstanses (the fail path order is incorrect). Fix that by checking
    > allocations in one turn and free all of them at once if some fails
    > (some may be NULL, but this is OK).

    Good catch, thanks!

    I generally prefer the static rather than lazy method of cleanup, but
    in this case it's ugly both before and after...


     \ /
      Last update: 2010-11-08 00:31    [W:0.018 / U:10.740 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site