diff options
author | Lennart Poettering <lennart@poettering.net> | 2012-09-11 03:03:36 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2012-09-11 03:03:36 +0200 |
commit | 49a32d43de3bd57bced22ed9a94342ea1efbb31c (patch) | |
tree | 50b7d9215d5ae391b573272e157a05e1c2de12a8 /src | |
parent | 48b617399d7d8446c5310b2568b2af6f13331b4c (diff) |
journal: don't set seal flag if we don't have gcrypt built-in
Diffstat (limited to 'src')
-rw-r--r-- | src/journal/journal-file.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/journal/journal-file.c b/src/journal/journal-file.c index 8bd52733c9..8016852b91 100644 --- a/src/journal/journal-file.c +++ b/src/journal/journal-file.c @@ -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); |