diff options
author | Zdenek Kabelac <zkabelac@redhat.com> | 2021-03-07 15:33:50 +0100 |
---|---|---|
committer | Zdenek Kabelac <zkabelac@redhat.com> | 2021-03-08 15:33:15 +0100 |
commit | 2d64ffaee521222e64b5c0bdfec367617e503f05 (patch) | |
tree | 237c78b1d7eef613ffa2de9f72e058e147a51d88 /lib/log | |
parent | 78c7ae7cd2dab7abf9ece9bec37979fa3b33c978 (diff) | |
download | lvm2-2d64ffaee521222e64b5c0bdfec367617e503f05.tar.gz |
hash: use individual hint sizes
Use different 'hint' size for dm_hash_create() call - so
when debug info about hash is printed we can recognize which
hash was in use.
This patch doesn't change actual used size since that is always
rounded to be power of 2 and >=16 - so as such is only a
help to developer.
We could eventually use 'name' arg, but since this would have changed
API and this patchset will be routed to libdm & stable - we will
just use this small trick.
Diffstat (limited to 'lib/log')
-rw-r--r-- | lib/log/log.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/log/log.c b/lib/log/log.c index ebf26b4de..cd676f2ae 100644 --- a/lib/log/log.c +++ b/lib/log/log.c @@ -576,7 +576,7 @@ static void _vprint_log(int level, const char *file, int line, int dm_errno_or_c if (log_once) { if (!_duplicated) - _duplicated = dm_hash_create(128); + _duplicated = dm_hash_create(117); if (_duplicated) { if (dm_hash_lookup(_duplicated, message)) level = _LOG_NOTICE; |