diff options
author | Mounir IDRASSI <mounir.idrassi@idrix.fr> | 2016-02-11 22:57:40 +0100 |
---|---|---|
committer | Mounir IDRASSI <mounir.idrassi@idrix.fr> | 2016-02-12 00:04:28 +0100 |
commit | 89d238bb3241fe8c285e9b748c0d99fa10b6a590 (patch) | |
tree | edbfc1229e282644c7469e4cdfbbff3ead0bf4e9 | |
parent | 7fee9a04c412840b6363b7d311d0bdf435feb5a3 (diff) | |
download | VeraCrypt-89d238bb3241fe8c285e9b748c0d99fa10b6a590.tar.gz VeraCrypt-89d238bb3241fe8c285e9b748c0d99fa10b6a590.zip |
Window: fix regression that caused only a single keyfile to be taken into account.
-rw-r--r-- | src/Common/Keyfiles.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Common/Keyfiles.c b/src/Common/Keyfiles.c index c634efaf..366d65ee 100644 --- a/src/Common/Keyfiles.c +++ b/src/Common/Keyfiles.c @@ -129,7 +129,9 @@ void KeyFileCloneAll (KeyFile *firstKeyFile, KeyFile **outputKeyFile) KeyFile *cloneFirstKeyFile = KeyFileClone (firstKeyFile);
KeyFile *kf;
- KeyFileRemoveAll (outputKeyFile);
+ // free output only if different from input
+ if (*outputKeyFile != firstKeyFile)
+ KeyFileRemoveAll (outputKeyFile);
if (firstKeyFile)
{
kf = firstKeyFile->Next;
|