Commit 3409aed
smb: client: fix query directory replay double-free
commit 9647492 upstream.
A response-bearing attempt can return a replayable error and free its
response buffer. If SMB2_query_directory_init() fails before the next send,
cleanup retains the previous buffer type and frees that response again.
Reset response bookkeeping before each attempt to prevent the stale free.
Fixes: 4f1fffa ("cifs: commands that are retried should have replay flag set")
Cc: stable@vger.kernel.org
Signed-off-by: Henrique Carvalho <henrique.carvalho@suse.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent f08b3f4 commit 3409aed
1 file changed
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5814 | 5814 | | |
5815 | 5815 | | |
5816 | 5816 | | |
| 5817 | + | |
| 5818 | + | |
5817 | 5819 | | |
5818 | 5820 | | |
5819 | 5821 | | |
| |||
0 commit comments