• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ LIST_TAIL_DATA函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中LIST_TAIL_DATA函数的典型用法代码示例。如果您正苦于以下问题:C++ LIST_TAIL_DATA函数的具体用法?C++ LIST_TAIL_DATA怎么用?C++ LIST_TAIL_DATA使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了LIST_TAIL_DATA函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: notify_up_handler

static void
notify_up_handler(vector_t *strvec)
{
	virtual_server_t *vs = LIST_TAIL_DATA(check_data->vs);
	real_server_t *rs = LIST_TAIL_DATA(vs->rs);
	rs->notify_up = set_value(strvec);
}
开发者ID:andriyanov,项目名称:keepalived,代码行数:7,代码来源:check_parser.c


示例2: inhibit_handler

static void
inhibit_handler(vector_t *strvec)
{
	virtual_server_t *vs = LIST_TAIL_DATA(check_data->vs);
	real_server_t *rs = LIST_TAIL_DATA(vs->rs);
	rs->inhibit = 1;
}
开发者ID:andriyanov,项目名称:keepalived,代码行数:7,代码来源:check_parser.c


示例3: lthreshold_handler

static void
lthreshold_handler(vector_t *strvec)
{
	virtual_server_t *vs = LIST_TAIL_DATA(check_data->vs);
	real_server_t *rs = LIST_TAIL_DATA(vs->rs);
	rs->l_threshold = atoi(vector_slot(strvec, 1));
}
开发者ID:andriyanov,项目名称:keepalived,代码行数:7,代码来源:check_parser.c


示例4: lthreshold_handler

static void
lthreshold_handler(vector strvec)
{
	virtual_server *vs = LIST_TAIL_DATA(check_data->vs);
	real_server *rs = LIST_TAIL_DATA(vs->rs);
	rs->l_threshold = atoi(VECTOR_SLOT(strvec, 1));
}
开发者ID:Addision,项目名称:LVS,代码行数:7,代码来源:check_parser.c


示例5: weight_handler

static void
weight_handler(vector_t *strvec)
{
	virtual_server_t *vs = LIST_TAIL_DATA(check_data->vs);
	real_server_t *rs = LIST_TAIL_DATA(vs->rs);
	rs->weight = atoi(vector_slot(strvec, 1));
	rs->iweight = rs->weight;
}
开发者ID:F191919,项目名称:keepalived,代码行数:8,代码来源:check_parser.c


示例6: checker_set_dst

/* Set dst */
void
checker_set_dst(struct sockaddr_storage *dst)
{
	virtual_server_t *vs = LIST_TAIL_DATA(check_data->vs);
	real_server_t *rs = LIST_TAIL_DATA(vs->rs);

	*dst = rs->addr;
}
开发者ID:daniel666,项目名称:dpvs,代码行数:9,代码来源:check_api.c


示例7: weight_handler

static void
weight_handler(vector strvec)
{
	virtual_server *vs = LIST_TAIL_DATA(check_data->vs);
	real_server *rs = LIST_TAIL_DATA(vs->rs);
	rs->weight = atoi(VECTOR_SLOT(strvec, 1));
	rs->iweight = rs->weight;
}
开发者ID:Addision,项目名称:LVS,代码行数:8,代码来源:check_parser.c


示例8: vrrp_notify_handler

static void
vrrp_notify_handler(vector_t *strvec)
{
	vrrp_t *vrrp = LIST_TAIL_DATA(vrrp_data->vrrp);
	vrrp->script = set_value(strvec);
	vrrp->notify_exec = 1;
}
开发者ID:vrit,项目名称:keepalived,代码行数:7,代码来源:vrrp_parser.c


示例9: vrrp_vmac_xmit_base_handler

static void
vrrp_vmac_xmit_base_handler(vector_t *strvec)
{
	vrrp_t *vrrp = LIST_TAIL_DATA(vrrp_data->vrrp);

	__set_bit(VRRP_VMAC_XMITBASE_BIT, &vrrp->vmac_flags);
}
开发者ID:vrit,项目名称:keepalived,代码行数:7,代码来源:vrrp_parser.c


示例10: vrrp_gnotify_handler

static void
vrrp_gnotify_handler(vector_t *strvec)
{
	vrrp_sgroup_t *vgroup = LIST_TAIL_DATA(vrrp_data->vrrp_sync_group);
	vgroup->script = set_value(strvec);
	vgroup->notify_exec = 1;
}
开发者ID:vrit,项目名称:keepalived,代码行数:7,代码来源:vrrp_parser.c


示例11: vrrp_vmac_xmit_base_handler

static void
vrrp_vmac_xmit_base_handler(vector_t *strvec)
{
	vrrp_t *vrrp = LIST_TAIL_DATA(vrrp_data->vrrp);
	if (vrrp->vmac_flags & VRRP_VMAC_FL_SET)
		vrrp->vmac_flags |= VRRP_VMAC_FL_XMITBASE;
}
开发者ID:LupusMichaelis,项目名称:keepalived,代码行数:7,代码来源:vrrp_parser.c


示例12: vrrp_vmac_handler

static void
vrrp_vmac_handler(vector_t *strvec)
{
	vrrp_t *vrrp = LIST_TAIL_DATA(vrrp_data->vrrp);
	vrrp->vmac |= 1;
	if (!vrrp->saddr)
		vrrp->saddr  = IF_ADDR(vrrp->ifp);
	if (vector_size(strvec) == 2) {
		strncpy(vrrp->vmac_ifname, vector_slot(strvec, 1),
			IFNAMSIZ - 1);
	} else if (vrrp->vrid) {
		snprintf(vrrp->vmac_ifname, IFNAMSIZ, "vrrp.%d", vrrp->vrid);
	}

	if (strlen(vrrp->vmac_ifname)) {
		log_message(LOG_INFO, "vmac_ifname=%s for vrrp_instace %s"
				    , vrrp->vmac_ifname
				    , vrrp->iname);
	}
	if (vrrp->ifp && !(vrrp->vmac & 2)) {
		unsigned int base_ifindex = vrrp->ifp->base_ifindex;
		netlink_link_add_vmac(vrrp);
		/* restore base ifindex (deleted when adding VMAC) */
		vrrp->ifp->base_ifindex = base_ifindex;
        }

        /* flag interface as a VMAC interface */
        vrrp->ifp->vmac = 1;
}
开发者ID:Olipro,项目名称:keepalived,代码行数:29,代码来源:vrrp_parser.c


示例13: vrrp_notify_master_handler

static void
vrrp_notify_master_handler(vector strvec)
{
	vrrp_rt *vrrp = LIST_TAIL_DATA(vrrp_data->vrrp);
	vrrp->script_master = set_value(strvec);
	vrrp->notify_exec = 1;
}
开发者ID:cyclops8456,项目名称:vyatta-keepalived,代码行数:7,代码来源:vrrp_parser.c


示例14: laddr_gname_handler

static void
laddr_gname_handler(vector_t *strvec)
{
        virtual_server_t *vs = LIST_TAIL_DATA(check_data->vs);

        vs->local_addr_gname = set_value(strvec);
}
开发者ID:tclh123,项目名称:lvs-tool,代码行数:7,代码来源:check_parser.c


示例15: bfd_nbrip_handler

static void
bfd_nbrip_handler(vector_t *strvec)
{
	bfd_t *bfd;
	struct sockaddr_storage nbr_addr;

	assert(strvec);
	assert(bfd_data);

	bfd = LIST_TAIL_DATA(bfd_data->bfd);
	assert(bfd);

	if (!strcmp(vector_slot(strvec, 1), "neighbour_ip"))
		neighbor_str = "neighbour";

	if (inet_stosockaddr(strvec_slot(strvec, 1), BFD_CONTROL_PORT, &nbr_addr)) {
		report_config_error(CONFIG_GENERAL_ERROR,
			    "Configuration error: BFD instance %s has"
			    " malformed %s address %s, ignoring instance",
			    bfd->iname, neighbor_str, FMT_STR_VSLOT(strvec, 1));
		list_del(bfd_data->bfd, bfd);
		skip_block(false);
		return;
	} else if (find_bfd_by_addr(&nbr_addr)) {
		report_config_error(CONFIG_GENERAL_ERROR,
			    "Configuration error: BFD instance %s has"
			    " duplicate %s address %s, ignoring instance",
			    bfd->iname, neighbor_str, FMT_STR_VSLOT(strvec, 1));
		list_del(bfd_data->bfd, bfd);
		skip_block(false);
		return;
	} else
		bfd->nbr_addr = nbr_addr;
}
开发者ID:acassen,项目名称:keepalived,代码行数:34,代码来源:bfd_parser.c


示例16: bfd_idletx_handler

static void
bfd_idletx_handler(vector_t *strvec)
{
	bfd_t *bfd;
	unsigned value;

	assert(strvec);
	assert(bfd_data);

	bfd = LIST_TAIL_DATA(bfd_data->bfd);
	assert(bfd);

	if (!read_unsigned_strvec(strvec, 1, &value,BFD_IDLETX_MIN, BFD_IDLETX_MAX, false))
		report_config_error(CONFIG_GENERAL_ERROR, "Configuration error: BFD instance %s"
			    " idle_tx value %s is not valid (must be in range"
			    " [%u-%u]), ignoring", bfd->iname, FMT_STR_VSLOT(strvec, 1),
			    BFD_IDLETX_MIN, BFD_IDLETX_MAX);
	else
		bfd->local_idle_tx_intv = value * 1000U;

	if (value > BFD_IDLETX_MAX_SENSIBLE)
		log_message(LOG_INFO, "Configuration warning: BFD instance %s"
			    " idle_tx value %u is larger than max sensible (%u)",
			    bfd->iname, value, BFD_IDLETX_MAX_SENSIBLE);
}
开发者ID:acassen,项目名称:keepalived,代码行数:25,代码来源:bfd_parser.c


示例17: alpha_handler

static void
alpha_handler(vector_t *strvec)
{
	virtual_server_t *vs = LIST_TAIL_DATA(check_data->vs);
	vs->alpha = 1;
	vs->quorum_state = DOWN;
}
开发者ID:F191919,项目名称:keepalived,代码行数:7,代码来源:check_parser.c


示例18: vs_end_handler

static void
vs_end_handler(void)
{
	virtual_server_t *vs = LIST_TAIL_DATA(check_data->vs);
	if (! vs->af)
		vs->af = AF_INET;
}
开发者ID:F191919,项目名称:keepalived,代码行数:7,代码来源:check_parser.c


示例19: proto_handler

static void
proto_handler(vector_t *strvec)
{
	virtual_server_t *vs = LIST_TAIL_DATA(check_data->vs);
	char *str = vector_slot(strvec, 1);
	vs->service_type = (!strcmp(str, "TCP")) ? IPPROTO_TCP : IPPROTO_UDP;
}
开发者ID:Grip,项目名称:keepalived-1,代码行数:7,代码来源:check_parser.c


示例20: vrrp_accept_handler

static void
vrrp_accept_handler(vector_t *strvec)
{
	vrrp_t *vrrp = LIST_TAIL_DATA(vrrp_data->vrrp);

	vrrp->accept = true;
}
开发者ID:vrit,项目名称:keepalived,代码行数:7,代码来源:vrrp_parser.c



注:本文中的LIST_TAIL_DATA函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ LIS_ObterValor函数代码示例发布时间:2022-05-30
下一篇:
C++ LIST_NUM函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap