Re: [patch 1/2] cifs: add kfree() on error path

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Oct 27, 2010 at 4:19 PM, Dan Carpenter <error27@xxxxxxxxx> wrote:
> We leak 256 bytes here on this error path.
>
> Signed-off-by: Dan Carpenter <error27@xxxxxxxxx>
>
> diff --git a/fs/cifs/file.c b/fs/cifs/file.c
> index 45af003..06a006b 100644
> --- a/fs/cifs/file.c
> +++ b/fs/cifs/file.c
> @@ -1353,6 +1353,7 @@ static int cifs_writepages(struct address_space *mapping,
>        if (!experimEnabled && tcon->ses->server->secMode &
>                        (SECMODE_SIGN_REQUIRED | SECMODE_SIGN_ENABLED)) {
>                cifsFileInfo_put(open_file);
> +               kfree(iov);
>                return generic_writepages(mapping, wbc);
>        }
>        cifsFileInfo_put(open_file);

Yes. obviously correct.- merged.

-- 
Thanks,

Steve
--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux