2010年11月1日 星期一

Error return

static int
_l2mldpxyHst_insertToGroupDB(
l2mldpxyHstVlanInfo_t * hstInfo_p,
l2mldpxyHstGroup_t *group_p
)
{

int ret=L2MLDPXY_E_NONE;
in6_addr_t * addr_p =(&group_p->groupAddr);
int hashValue=_l2mldpxyHst_hashGroup(addr_p);


l2mldpxyFuncPrint("@_l2mldpxyHst_insertToGroupDB\n");

/*sanity check*/
if (!hstInfo_p){
  ret = -1;
  goto exit;
}


LIST_INSERT_HEAD(hstInfo_p->groupDB[hashValue],group_p,linkHead_hash);

exit:
if (ret) l2mldpxyFuncPrint("Fail! ret code=%d\n", ret); 
return ret;

}

沒有留言:

張貼留言