return FRSH_ERR_ALREADY_BOUND;
ep->vres = vres;
- rv = fwp_vres_bind(vres, ep, ep->sockd);
+ rv = fwp_vres_bind(vres, ep, ep->sockd, &ep->src);
return rv;
}
}
/*int fwp_vres_bind(fwp_vres_t *vres, struct fwp_endpoint *epoint)*/
-int fwp_vres_bind(fwp_vres_t *vres, struct fwp_endpoint *ep, int sockd)
+int fwp_vres_bind(fwp_vres_t *vres, struct fwp_endpoint *ep, int sockd, struct in_addr *src)
{
int rv = 0;
}
vres->ac_sockd = sockd;
+ *src = vres->params.src;
rv = fwp_vres_set_ac(vres->ac_sockd, vres->params.ac_id);
if (rv)
goto err;
struct fwp_endpoint;
int fwp_vres_enqueue(struct fwp_vres *vres, struct fwp_endpoint *ep,
const void *msg, size_t size);
-int fwp_vres_bind(fwp_vres_t *vres, struct fwp_endpoint *ep, int sockd);
+int fwp_vres_bind(fwp_vres_t *vres, struct fwp_endpoint *ep, int sockd, struct in_addr *src);
int fwp_vres_unbind(fwp_vres_t *vres);
extern fwp_vres_params_t fwp_vres_params_default;