]> www.infradead.org Git - mtd-utils.git/commit
mkfs.ubifs: Fix runtime assertions when running without crypto
authorHenri Roosen <henriroosen@gmail.com>
Mon, 8 Mar 2021 14:57:10 +0000 (15:57 +0100)
committerDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>
Mon, 22 Mar 2021 00:24:01 +0000 (01:24 +0100)
commit1709a628dfc8983f7718e978676cafc3c0399a70
tree0710ff4f4b103ac257ba2fcbab6c2533f3ed5b10
parente91700286ff531f344f4d9a1f1c96c501bfeadad
mkfs.ubifs: Fix runtime assertions when running without crypto

Running mkfs.ubifs which was build without crypto triggered the
following assertion:

mkfs.ubifs: ubifs-utils/mkfs.ubifs/fscrypt.h:166:
inherit_fscrypt_context: Assertion `0' failed.

A previous commit-cc4c5e295f54 ("mkfs.ubifs: Enable support for building
without crypto") added a check for an existing fscrypt context before calling
functions inherit_fscrypt_context() and free_fscrypt_context(),
however did not properly do this for each call to these functions.

Fixes: cc4c5e295f54 ("mkfs.ubifs: Enable support for building without crypto")
Signed-off-by: Henri Roosen <henri.roosen@ginzinger.com>
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
ubifs-utils/mkfs.ubifs/fscrypt.h