if (blc == 0) return(NULL);
collapse_blacklist(struct bl *bl, int blc){	int bs = 0, ws = 0, state=0, cli, i;	struct cidr ** cl;	u_int32_t bstart = 0;	cl = malloc((blc / 2) * sizeof(struct cidr));	if (cl == NULL) {		return (NULL);	}	qsort(bl, blc, sizeof(struct bl), cmpbl);	cli = 0;	cl[cli] = NULL;	for (i = 0; i < blc;) {		int laststate = state;		u_int32_t addr = bl[i].addr;		do {			bs += bl[i].b;			ws += bl[i].w;			i++ ;		} while (bl[i].addr == addr);		if (state == 1 && bs == 0)			state = 0;		else if (state == 0 && bs > 0)			state = 1;		if (ws > 0)			state = 0;		if (laststate == 0 && state == 1) {			/* start blacklist */			bstart = addr;		}		if (laststate == 1 && state == 0) {			/* end blacklist */			cl[cli++] = range2cidrlist(bstart, addr - 1);			cl[cli] = NULL;		}		laststate = state;	}	return (cl);}