From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.linuxfoundation.org ([140.211.169.12]:49592 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752101AbcJZJY7 (ORCPT ); Wed, 26 Oct 2016 05:24:59 -0400 Subject: Patch "Cleanup missing frees on some ioctls" has been added to the 4.8-stable tree To: smfrench@gmail.com, gregkh@linuxfoundation.org, sprabhu@redhat.com Cc: , From: Date: Wed, 26 Oct 2016 11:25:01 +0200 Message-ID: <14774739014367@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org List-ID: This is a note to let you know that I've just added the patch titled Cleanup missing frees on some ioctls to the 4.8-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: cleanup-missing-frees-on-some-ioctls.patch and it can be found in the queue-4.8 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let know about it. >>From 24df1483c272c99ed88b0cba135d0e1dfdee3930 Mon Sep 17 00:00:00 2001 From: Steve French Date: Thu, 29 Sep 2016 04:20:23 -0500 Subject: Cleanup missing frees on some ioctls From: Steve French commit 24df1483c272c99ed88b0cba135d0e1dfdee3930 upstream. Cleanup some missing mem frees on some cifs ioctls, and clarify others to make more obvious that no data is returned. Signed-off-by: Steve French Acked-by: Sachin Prabhu Signed-off-by: Greg Kroah-Hartman --- fs/cifs/smb2ops.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) --- a/fs/cifs/smb2ops.c +++ b/fs/cifs/smb2ops.c @@ -287,7 +287,7 @@ SMB3_request_interfaces(const unsigned i cifs_dbg(FYI, "Link Speed %lld\n", le64_to_cpu(out_buf->LinkSpeed)); } - + kfree(out_buf); return rc; } #endif /* STATS2 */ @@ -700,6 +700,7 @@ smb2_clone_range(const unsigned int xid, cchunk_out: kfree(pcchunk); + kfree(retbuf); return rc; } @@ -824,7 +825,6 @@ smb2_duplicate_extents(const unsigned in { int rc; unsigned int ret_data_len; - char *retbuf = NULL; struct duplicate_extents_to_file dup_ext_buf; struct cifs_tcon *tcon = tlink_tcon(trgtfile->tlink); @@ -850,7 +850,7 @@ smb2_duplicate_extents(const unsigned in FSCTL_DUPLICATE_EXTENTS_TO_FILE, true /* is_fsctl */, (char *)&dup_ext_buf, sizeof(struct duplicate_extents_to_file), - (char **)&retbuf, + NULL, &ret_data_len); if (ret_data_len > 0) @@ -873,7 +873,6 @@ smb3_set_integrity(const unsigned int xi struct cifsFileInfo *cfile) { struct fsctl_set_integrity_information_req integr_info; - char *retbuf = NULL; unsigned int ret_data_len; integr_info.ChecksumAlgorithm = cpu_to_le16(CHECKSUM_TYPE_UNCHANGED); @@ -885,7 +884,7 @@ smb3_set_integrity(const unsigned int xi FSCTL_SET_INTEGRITY_INFORMATION, true /* is_fsctl */, (char *)&integr_info, sizeof(struct fsctl_set_integrity_information_req), - (char **)&retbuf, + NULL, &ret_data_len); } Patches currently in stable-queue which might be from smfrench@gmail.com are queue-4.8/fix-regression-which-breaks-dfs-mounting.patch queue-4.8/cleanup-missing-frees-on-some-ioctls.patch queue-4.8/smb3-guids-should-be-constructed-as-random-but-valid-uuids.patch queue-4.8/clarify-locking-of-cifs-file-and-tcon-structures-and-make-more-granular.patch queue-4.8/do-not-send-smb3-set_info-request-if-nothing-is-changing.patch queue-4.8/set-previous-session-id-correctly-on-smb3-reconnect.patch queue-4.8/cifs-limit-the-overall-credit-acquired.patch queue-4.8/fs-cifs-keep-guid-when-assigning-fid-to-fileinfo.patch queue-4.8/display-number-of-credits-available.patch