Lines Matching refs:lookup

59 struct lookup {  struct
291 struct lookup *lookup; in server_del() local
309 lookup = container_of(li, struct lookup, li); in server_del()
310 if (lookup->service && lookup->service != srv->service) in server_del()
312 if (lookup->instance && lookup->instance != srv->instance) in server_del()
315 lookup_notify(ctx, &lookup->sq, srv, false); in server_del()
387 struct lookup *lookup; in ctrl_cmd_del_client() local
404 lookup = container_of(li, struct lookup, li); in ctrl_cmd_del_client()
405 if (lookup->sq.sq_node != node_id) in ctrl_cmd_del_client()
407 if (lookup->sq.sq_port != port) in ctrl_cmd_del_client()
410 list_remove(&ctx->lookups, &lookup->li); in ctrl_cmd_del_client()
411 free(lookup); in ctrl_cmd_del_client()
448 struct lookup *lookup; in ctrl_cmd_new_server() local
471 lookup = container_of(li, struct lookup, li); in ctrl_cmd_new_server()
472 if (lookup->service && lookup->service != service) in ctrl_cmd_new_server()
474 if (lookup->instance && lookup->instance != instance) in ctrl_cmd_new_server()
477 lookup_notify(ctx, &lookup->sq, srv, true); in ctrl_cmd_new_server()
516 struct lookup *lookup; in ctrl_cmd_new_lookup() local
524 lookup = calloc(1, sizeof(*lookup)); in ctrl_cmd_new_lookup()
525 if (!lookup) in ctrl_cmd_new_lookup()
528 lookup->sq = *from; in ctrl_cmd_new_lookup()
529 lookup->service = service; in ctrl_cmd_new_lookup()
530 lookup->instance = instance; in ctrl_cmd_new_lookup()
531 list_append(&ctx->lookups, &lookup->li); in ctrl_cmd_new_lookup()
552 struct lookup *lookup; in ctrl_cmd_del_lookup() local
557 lookup = container_of(li, struct lookup, li); in ctrl_cmd_del_lookup()
558 if (lookup->sq.sq_node != from->sq_node) in ctrl_cmd_del_lookup()
560 if (lookup->sq.sq_port != from->sq_port) in ctrl_cmd_del_lookup()
562 if (lookup->service != service) in ctrl_cmd_del_lookup()
564 if (lookup->instance && lookup->instance != instance) in ctrl_cmd_del_lookup()
567 list_remove(&ctx->lookups, &lookup->li); in ctrl_cmd_del_lookup()
568 free(lookup); in ctrl_cmd_del_lookup()