chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
journal: replace contexts hashmap with a plain array
[elogind.git]
/
src
/
journal
/
journal-file.c
diff --git
a/src/journal/journal-file.c
b/src/journal/journal-file.c
index 82e50fcca4229a403a6e8bd3b29b8d547077d100..7cdaf2920b8c13d94892323bc3c98394facc7fc3 100644
(file)
--- a/
src/journal/journal-file.c
+++ b/
src/journal/journal-file.c
@@
-376,6
+376,7
@@
static int journal_file_allocate(JournalFile *f, uint64_t offset, uint64_t size)
static unsigned type_to_context(ObjectType type) {
/* One context for each type, plus one catch-all for the rest */
+ assert_cc(_OBJECT_TYPE_MAX <= MMAP_CACHE_MAX_CONTEXTS);
return type > OBJECT_UNUSED && type < _OBJECT_TYPE_MAX ? type : 0;
}