deps/kb_meme/meme-5.0.1/src/array-list.c
/*
 * arraylst_destroy
 * Destroys the array list. Will optionally destroy the contained items if
 * passed a destructor function. For simple things passing free will surfice.
 */
arraylst_destroy
Destroys the array list. Will optionally destroy the contained items if
passed a destructor function. For simple things passing free will surfice.
arraylst_destroy Destroys the array list . Will optionally destroy the contained items if passed a destructor function . For simple things passing free will surfice .
void arraylst_destroy(void (*optional_item_destructor)(void*), ARRAYLST_T *arraylst) {
  if (arraylst == NULL) die("arraylst_destroy: arraylst is null!\n");
  if (optional_item_destructor != NULL) arraylst_apply(optional_item_destructor, arraylst);
  if (arraylst->cur_alloc > 0) free(arraylst->array);
  free(arraylst);
}
void arraylst_destroy ( void ( * optional_item_destructor ) ( void * ) , ARRAYLST_T * arraylst ) { if ( arraylst == NULL ) die ( " \n " ) ; if ( optional_item_destructor != NULL ) arraylst_apply ( optional_item_destructor , arraylst ) ; if ( arraylst -> cur_alloc > 0 ) free ( arraylst -> array ) ; free ( arraylst ) ; }
arraylst_destroy
 Destroys the array list.
arraylst_destroy Destroys the array list .
//test parameters