Lines Matching defs:obj
44 #define CLEANUP_OBJ(obj) \
45 do { if ((obj) != NULL) cfg_obj_destroy(pctx, &(obj)); } while (0)
63 print_keyvalue(cfg_printer_t *pctx, const cfg_obj_t *obj);
471 print_none(cfg_printer_t *pctx, const cfg_obj_t *obj) {
472 UNUSED(obj);
512 print_hostname(cfg_printer_t *pctx, const cfg_obj_t *obj) {
513 UNUSED(obj);
584 cfg_obj_t *obj = NULL;
599 CHECK(cfg_create_tuple(pctx, &cfg_type_porttuple, &obj));
600 CHECK(parse_port(pctx, &obj->value.tuple[0]));
601 CHECK(parse_port(pctx, &obj->value.tuple[1]));
602 if (obj->value.tuple[0]->value.uint32 >
603 obj->value.tuple[1]->value.uint32) {
607 obj->value.tuple[0]->value.uint32);
611 *ret = obj;
612 obj = NULL;
616 if (obj != NULL)
617 cfg_obj_destroy(pctx, &obj);
1218 cfg_obj_t *obj = NULL;
1230 CHECK(cfg_create_obj(pctx, &cfg_type_uint64, &obj));
1231 obj->value.uint64 = val;
1232 *ret = obj;
1279 cfg_obj_t *obj = NULL;
1286 CHECK(kw->type->parse(pctx, kw->type, &obj));
1287 obj->type = type; /* XXX kludge */
1290 CHECK(cfg_parse_void(pctx, NULL, &obj));
1298 *ret = obj;
1339 print_keyvalue(cfg_printer_t *pctx, const cfg_obj_t *obj) {
1340 const keyword_type_t *kw = obj->type->of;
1343 kw->type->print(pctx, obj);
1570 cfg_obj_t *obj = NULL;
1621 CHECK(cfg_create_obj(pctx, &cfg_type_querysource, &obj));
1622 isc_sockaddr_fromnetaddr(&obj->value.sockaddr, &netaddr, port);
1623 *ret = obj;
1628 CLEANUP_OBJ(obj);
1633 print_querysource(cfg_printer_t *pctx, const cfg_obj_t *obj) {
1635 isc_netaddr_fromsockaddr(&na, &obj->value.sockaddr);
1639 cfg_print_rawuint(pctx, isc_sockaddr_getport(&obj->value.sockaddr));
1715 print_negated(cfg_printer_t *pctx, const cfg_obj_t *obj) {
1717 cfg_print_tuple(pctx, obj);
1888 cfg_obj_t *obj = NULL;
1891 CHECK(cfg_create_tuple(pctx, type, &obj));
1894 CHECK(cfg_parse_obj(pctx, fields[0].type, &obj->value.tuple[0]));
1903 obj->value.tuple[1] == NULL) {
1905 &obj->value.tuple[1]));
1908 obj->value.tuple[2] == NULL) {
1910 &obj->value.tuple[2]));
1920 if (obj->value.tuple[1] == NULL)
1921 CHECK(cfg_parse_void(pctx, NULL, &obj->value.tuple[1]));
1922 if (obj->value.tuple[2] == NULL)
1923 CHECK(cfg_parse_void(pctx, NULL, &obj->value.tuple[2]));
1925 *ret = obj;
1929 CLEANUP_OBJ(obj);
1934 print_logfile(cfg_printer_t *pctx, const cfg_obj_t *obj) {
1935 cfg_print_obj(pctx, obj->value.tuple[0]); /* file */
1936 if (obj->value.tuple[1]->type->print != cfg_print_void) {
1938 cfg_print_obj(pctx, obj->value.tuple[1]);
1940 if (obj->value.tuple[2]->type->print != cfg_print_void) {
1942 cfg_print_obj(pctx, obj->value.tuple[2]);
2126 cfg_obj_t *obj = NULL;
2138 &obj));
2140 &obj->value.tuple[0]));
2142 &obj->value.tuple[1]));
2143 *ret = obj;
2144 obj = NULL;
2152 CLEANUP_OBJ(obj);
2208 cfg_obj_t *obj = NULL;
2224 CLEANUP_OBJ(obj);