summaryrefslogtreecommitdiffstats
path: root/kpat/freecell-solver/fcs_hash.c
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-11 04:58:26 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-11 04:58:26 +0000
commit838baf3f99ec5ab81b063eb5449a3381d860f377 (patch)
treedd31abcfde08ca92e4623b8f50b3d762a87c997a /kpat/freecell-solver/fcs_hash.c
parent2bf598bafa22fac4126fc8842df6b0119aadc0e9 (diff)
downloadtdegames-838baf3f99ec5ab81b063eb5449a3381d860f377.tar.gz
tdegames-838baf3f99ec5ab81b063eb5449a3381d860f377.zip
TQt4 port kdegames
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegames@1236074 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kpat/freecell-solver/fcs_hash.c')
-rw-r--r--kpat/freecell-solver/fcs_hash.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/kpat/freecell-solver/fcs_hash.c b/kpat/freecell-solver/fcs_hash.c
index fde7a03f..2ae2d60b 100644
--- a/kpat/freecell-solver/fcs_hash.c
+++ b/kpat/freecell-solver/fcs_hash.c
@@ -53,7 +53,7 @@ SFO_hash_t * freecell_solver_hash_init(
hash = (SFO_hash_t *)malloc(sizeof(SFO_hash_t));
hash->size = size;
- hash->size_bitmask = size-1;
+ hash->size_bittqmask = size-1;
hash->num_elems = 0;
@@ -87,7 +87,7 @@ void * freecell_solver_hash_insert(
SFO_hash_symlink_item_t * item, * last_item;
/* Get the index of the appropriate chain in the hash table */
- place = hash_value & (hash->size_bitmask);
+ place = hash_value & (hash->size_bittqmask);
list = &(hash->entries[place]);
/* If first_item is non-existent */
@@ -220,7 +220,7 @@ static void SFO_hash_rehash(
SFO_hash_t * hash
)
{
- int old_size, new_size, new_size_bitmask;
+ int old_size, new_size, new_size_bittqmask;
int i;
#if 0
SFO_hash_t * new_hash;
@@ -242,7 +242,7 @@ static void SFO_hash_rehash(
old_size = hash->size;
new_size = old_size << 1;
- new_size_bitmask = new_size - 1;
+ new_size_bittqmask = new_size - 1;
new_entries = calloc(new_size, sizeof(SFO_hash_symlink_t));
@@ -254,7 +254,7 @@ static void SFO_hash_rehash(
while(item != NULL)
{
/* The place in the new hash table */
- place = item->hash_value & new_size_bitmask;
+ place = item->hash_value & new_size_bittqmask;
/* Store the next item in the linked list in a safe place,
so we can retrieve it after the assignment */
@@ -280,7 +280,7 @@ static void SFO_hash_rehash(
#endif
hash->entries = new_entries;
hash->size = new_size;
- hash->size_bitmask = new_size_bitmask;
+ hash->size_bittqmask = new_size_bittqmask;
}
#else