mirror of
https://github.com/AuxXxilium/eudev.git
synced 2024-12-25 21:25:59 +07:00
journal: don't set seal flag if we don't have gcrypt built-in
This commit is contained in:
parent
48b617399d
commit
49a32d43de
@ -2024,7 +2024,9 @@ int journal_file_open(
|
||||
#ifdef HAVE_XZ
|
||||
f->compress = compress;
|
||||
#endif
|
||||
#ifdef HAVE_GCRYPT
|
||||
f->seal = seal;
|
||||
#endif
|
||||
|
||||
if (mmap_cache)
|
||||
f->mmap = mmap_cache_ref(mmap_cache);
|
||||
@ -2059,9 +2061,11 @@ int journal_file_open(
|
||||
#ifdef HAVE_GCRYPT
|
||||
/* Try to load the FSPRG state, and if we can't, then
|
||||
* just don't do sealing */
|
||||
r = journal_file_fss_load(f);
|
||||
if (r < 0)
|
||||
f->seal = false;
|
||||
if (f->seal) {
|
||||
r = journal_file_fss_load(f);
|
||||
if (r < 0)
|
||||
f->seal = false;
|
||||
}
|
||||
#endif
|
||||
|
||||
r = journal_file_init_header(f, template);
|
||||
|
Loading…
Reference in New Issue
Block a user