if (new_offset >= spp[i]->p_offset && new_offset < spp[i]->p_offset + spp[i]->p_size)
if ((new_offset >= spp[i]->p_offset && new_offset < spp[i]->p_offset + spp[i]->p_size) || (new_offset + pp->p_size >= spp[i]->p_offset && new_offset + pp->p_size <= spp[i]->p_offset + spp[i]->p_size))
next_offset(lp)	struct disklabel *lp;{	struct partition **spp;	u_int16_t npartitions;	u_int32_t new_offset = 0;	int i;	/* Get a sorted list of the partitions */	spp = sort_partitions(lp, &npartitions);	for (i = 0; i < npartitions; i++ ) {		/*		 * Is new_offset inside this partition?  If so,		 * make it the next block after the partition ends.		 */		if (new_offset >= spp[i]->p_offset &&		    new_offset < spp[i]->p_offset + spp[i]->p_size)			new_offset = spp[i]->p_offset + spp[i]->p_size;	}	(void)free(spp);	return(new_offset);}