1
Fork 0

Fixed: gcc 2.95 problem and initialzes memory

This commit is contained in:
fc_botelho 2005-09-02 17:31:23 +00:00
parent 1d6ef167f6
commit 1d9e0c2c81
1 changed files with 3 additions and 2 deletions

View File

@ -19,14 +19,15 @@ static void chm_traverse(chm_config_data_t *chm, cmph_uint8 *visited, cmph_uint3
chm_config_data_t *chm_config_new()
{
chm_config_data_t *chm = NULL;
chm_config_data_t *chm;
chm = (chm_config_data_t *)malloc(sizeof(chm_config_data_t));
assert(chm);
memset(chm,0,sizeof(chm_config_data_t));
chm->hashfuncs[0] = CMPH_HASH_JENKINS;
chm->hashfuncs[1] = CMPH_HASH_JENKINS;
chm->g = NULL;
chm->graph = NULL;
chm->hashes = NULL;
assert(chm);
return chm;
}
void chm_config_destroy(cmph_config_t *mph)