Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Fix size misrepresentation in HklHash #126

merged 4 commits into from Jan 9, 2013


None yet
2 participants

cknadler commented Jan 9, 2013

HklHash had a nasty bug where the size of the hash wouldn't be decremented if you attempted to remove a value that was stored in a HklTree (which means it was involved in a collision during insertion).

This was fixed by adding a size attribute the the HklTree and using that attribute when removing values from a tree contained within the hash.

Closes #125

/cc @pyrated

cknadler added some commits Jan 9, 2013

@cknadler cknadler Typo in HklHash header 0a45d3b
@cknadler cknadler Fixes HklHash misrepresenting size
HklHash had a small bug in the insert function causing it to double
in size much too often and misrepresent the number of buckets used.
@cknadler cknadler Adds size to hkl_tree 642bbb3
@cknadler cknadler Fixes size issue with HklHash
Uses the new size implemented in HklTree to properly update the size of
the hash when a value is attempted to be removed from a tree in the

@pyrated pyrated added a commit that referenced this pull request Jan 9, 2013

@pyrated pyrated Merge pull request #126 from cknadler/master
Fix size misrepresentation in HklHash

@pyrated pyrated merged commit 04e5ea7 into hkl:master Jan 9, 2013

1 check passed

default The Travis build passed

pyrated commented Jan 9, 2013

You are a pro


cknadler commented Jan 9, 2013

Dawww. ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment