combine these two functions and calculate the number of total edges yourself:

Code:
// returns the number of nodes of a an entity assigned path
function path_totalnodecount(ENTITY* p_e){
var lv_cnt = 1;

	while(path_getnode(p_e,lv_cnt,temp,gv_nskill)!=0){lv_cnt+=1;}
	return(lv_cnt-1);
	
}

and
Code:
// get the number of edges of a node
function path_getedgecnt(ENTITY* p_e,var p_node){
var lv_ret;
var lv_ec = 0;	
	
	// get edge count
	while(path_getedge(p_e,p_node,lv_ec+1,temp)!=0){lv_ec+=1;}
	return(lv_ec);
	
}