예제 #1
0
//desaloca Hash h
void apagaHash(Hash* h,int boolSBB){
	int i=0;
	if(boolSBB==0){
		for(i=0; i<h->tam;i++){
			apagaArvore(h->hash[i]);
		}
		free(h->hash);
	}else{
			for(i=0; i<h->tam;i++){
				apagaArvoreSBB(h->hashSBB[i]);
			}
			free(h->hashSBB);
		}
	free(h);
}
예제 #2
0
파일: hash.c 프로젝트: I-Spangler/trees
void apagaHash(Hash* h, int type){
  int i;
  if(type == 0){
    for(i=0; i<h->tam;i++){
      apagaArvore(h->hash[i]);
    }
    free(h->hash);
  }
  if(type == 1){
    for(i=0; i<h->tam;i++){
      apagaSBB(h->hashSBB[i]);
    }
    free(h->hashSBB);
  }
  free(h);
}