Skip to content
Commit 8e20ba2e authored by Lasse Collin's avatar Lasse Collin Committed by Linus Torvalds
Browse files

lib/xz: fix XZ_DYNALLOC to avoid useless memory reallocations

s->dict.allocated was initialized to 0 but never set after a successful
allocation, thus the code always thought that the dictionary buffer has
to be reallocated.

Link: http://lkml.kernel.org/r/20191104185107.3b6330df@tukaani.org


Signed-off-by: default avatarLasse Collin <lasse.collin@tukaani.org>
Reported-by: default avatarYu Sun <yusun2@cisco.com>
Acked-by: default avatarDaniel Walker <danielwa@cisco.com>
Cc: "Yixia Si (yisi)" <yisi@cisco.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 82072962
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment