Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1740672
| From | Jeffy Chen <jeffy.chen@rock-chips.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH] dm-crypt: Fix memory leak in crypt_ctr_cipher_old() |
| Date | 2017-09-27 14:30 +0200 |
| Message-ID | <uujDs-2nV-23@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
Fix memory leak of cipher_api. Fixes: 33d2f09fcb35 (dm crypt: introduce new format of cipher with "capi:" prefix) Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com> --- drivers/md/dm-crypt.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/md/dm-crypt.c b/drivers/md/dm-crypt.c index a55ffd4f5933..04be8ce1742e 100644 --- a/drivers/md/dm-crypt.c +++ b/drivers/md/dm-crypt.c @@ -2467,6 +2467,7 @@ static int crypt_ctr_cipher_old(struct dm_target *ti, char *cipher_in, char *key return ret; } + kfree(cipher_api); return 0; bad_mem: ti->error = "Cannot allocate cipher strings"; -- 2.11.0
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH] dm-crypt: Fix memory leak in crypt_ctr_cipher_old() Jeffy Chen <jeffy.chen@rock-chips.com> - 2017-09-27 14:30 +0200 Re: dm-crypt: Fix memory leak in crypt_ctr_cipher_old() Mike Snitzer <snitzer@redhat.com> - 2017-09-28 18:30 +0200
csiph-web