~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to storage/innobase/include/hash0hash.ic

  • Committer: Monty Taylor
  • Date: 2008-09-15 17:24:04 UTC
  • Revision ID: monty@inaugust.com-20080915172404-ygh6hiyu0q7qpa9x
Removed strndup calls.

Show diffs side-by-side

added added

removed removed

Lines of Context:
24
24
}
25
25
 
26
26
/*****************************************************************
27
 
Clears a hash table so that all the cells become empty. */
28
 
UNIV_INLINE
29
 
void
30
 
hash_table_clear(
31
 
/*=============*/
32
 
        hash_table_t*   table)  /* in/out: hash table */
33
 
{
34
 
        memset(table->array, 0x0,
35
 
               table->n_cells * sizeof(*table->array));
36
 
}
37
 
 
38
 
/*****************************************************************
39
27
Returns the number of cells in a hash table. */
40
28
UNIV_INLINE
41
29
ulint
70
58
        hash_table_t*   table,  /* in: hash table */
71
59
        ulint           fold)   /* in: fold */
72
60
{
73
 
        ut_ad(ut_is_2pow(table->n_mutexes));
74
61
        return(ut_2pow_remainder(fold, table->n_mutexes));
75
62
}
76
63