diff options
author | Paweł Redman <pawel.redman@gmail.com> | 2017-06-21 18:35:35 +0200 |
---|---|---|
committer | Paweł Redman <pawel.redman@gmail.com> | 2017-06-21 18:35:35 +0200 |
commit | 9fbadf8d0599ca1ce68bbb400a227d514b09d412 (patch) | |
tree | f24c0c4d0c74b9a158bda09b24995ac3a6433937 /src | |
parent | 85ecf73037f74bc798429a1a989e9a2ac6227ca7 (diff) |
Diffstat (limited to 'src')
-rw-r--r-- | src/database.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/database.c b/src/database.c index b3ffb7f..373ce62 100644 --- a/src/database.c +++ b/src/database.c @@ -26,7 +26,7 @@ static size_t db_hash(uint32_t ipv4) return (((ipv4 >> 16) ^ ipv4) * 3137) & HASH_MAX; } -db_entry *database[HASH_MAX]; +db_entry *database[HASH_MAX + 1]; pthread_mutex_t database_mutex = PTHREAD_MUTEX_INITIALIZER; // Returns a pointer to the relevant db_entry (newly created if didn't exist). |