67 if (status != ISC_R_SUCCESS)
68 log_fatal (
"Can't register control object type: %s",
69 isc_result_totext (status));
71 if (status != ISC_R_SUCCESS)
72 log_fatal (
"Can't make initial control object: %s",
73 isc_result_totext (status));
88 if (status != ISC_R_SUCCESS)
89 log_fatal (
"Can't register group object type: %s",
90 isc_result_totext (status));
102 sizeof (
struct subnet), 0,
104 if (status != ISC_R_SUCCESS)
105 log_fatal (
"Can't register subnet object type: %s",
106 isc_result_totext (status));
120 if (status != ISC_R_SUCCESS)
121 log_fatal (
"Can't register shared network object type: %s",
122 isc_result_totext (status));
149 return ISC_R_NOMEMORY;
156 return ISC_R_SUCCESS;
164 return ISC_R_NOMEMORY;
172 (
char *) value->
u.
buffer.value,
174 "network client", 0);
175 if (status != ISC_R_SUCCESS ||
parse == NULL)
184 return ISC_R_SUCCESS;
190 if (h -> inner && h -> inner -> type -> set_value) {
191 status = ((*(h -> inner -> type -> set_value))
192 (h -> inner, id, name, value));
197 return ISC_R_NOTFOUND;
217 if (h -> inner && h -> inner -> type -> get_value) {
218 status = ((*(h -> inner -> type -> get_value))
219 (h -> inner, id,
name, value));
220 if (status == ISC_R_SUCCESS)
223 return ISC_R_NOTFOUND;
244 group_object_dereference (&t,
MDL);
253 return ISC_R_SUCCESS;
257 const char *
name, va_list ap)
267 if (!strcmp (
name,
"updated")) {
276 sprintf (hnbuf,
"ng%08lx%08lx",
278 (
unsigned long)
group);
281 return ISC_R_NOMEMORY;
290 if (h -> inner && h -> inner -> type -> get_value) {
291 status = ((*(h -> inner -> type -> signal_handler))
292 (h -> inner,
name, ap));
293 if (status == ISC_R_SUCCESS)
297 return ISC_R_SUCCESS;
298 return ISC_R_NOTFOUND;
315 if (status != ISC_R_SUCCESS)
318 if (status != ISC_R_SUCCESS)
323 if (h -> inner && h -> inner -> type -> stuff_values) {
324 status = ((*(h -> inner -> type -> stuff_values))
325 (c, id, h -> inner));
326 if (status == ISC_R_SUCCESS)
330 return ISC_R_SUCCESS;
345 if (status == ISC_R_SUCCESS) {
349 if (status != ISC_R_SUCCESS)
361 if (status == ISC_R_SUCCESS) {
366 tv -> value -> u.buffer.
value,
367 tv -> value -> u.buffer.len,
MDL)) {
371 group_object_dereference (&
group,
MDL);
380 group_object_dereference (&
group,
MDL);
383 return ISC_R_NOTFOUND;
393 return ISC_R_NOTFOUND;
395 return ISC_R_SUCCESS;
405 status = group_object_allocate (&
group,
MDL);
406 if (status != ISC_R_SUCCESS)
410 group_object_dereference (&
group,
MDL);
426 return ISC_R_IOERROR;
441 unsigned long newstate;
449 if (status != ISC_R_SUCCESS)
452 if (status == ISC_R_SUCCESS)
453 control -> state = value -> u.
integer;
458 if (h -> inner && h -> inner -> type -> set_value) {
459 status = ((*(h -> inner -> type -> set_value))
460 (h -> inner, id,
name, value));
465 return ISC_R_NOTFOUND;
482 name, (
int)control -> state,
MDL);
485 if (h -> inner && h -> inner -> type -> get_value) {
486 status = ((*(h -> inner -> type -> get_value))
487 (h -> inner, id,
name, value));
488 if (status == ISC_R_SUCCESS)
491 return ISC_R_NOTFOUND;
505 const char *
name, va_list ap)
515 if (h -> inner && h -> inner -> type -> get_value) {
516 status = ((*(h -> inner -> type -> signal_handler))
517 (h -> inner,
name, ap));
518 if (status == ISC_R_SUCCESS)
521 return ISC_R_NOTFOUND;
537 if (status != ISC_R_SUCCESS)
540 if (status != ISC_R_SUCCESS)
543 if (status != ISC_R_SUCCESS)
547 if (h -> inner && h -> inner -> type -> stuff_values) {
548 status = ((*(h -> inner -> type -> stuff_values))
549 (c, id, h -> inner));
550 if (status == ISC_R_SUCCESS)
554 return ISC_R_SUCCESS;
566 if (status == ISC_R_SUCCESS) {
570 if (status != ISC_R_SUCCESS)
585 return ISC_R_SUCCESS;
618 if (h -> inner && h -> inner -> type -> set_value) {
619 status = ((*(h -> inner -> type -> set_value))
620 (h -> inner, id,
name, value));
625 return ISC_R_NOTFOUND;
643 if (h -> inner && h -> inner -> type -> get_value) {
644 status = ((*(h -> inner -> type -> get_value))
645 (h -> inner, id,
name, value));
646 if (status == ISC_R_SUCCESS)
649 return ISC_R_NOTFOUND;
672 return ISC_R_SUCCESS;
676 const char *name, va_list ap)
688 if (h -> inner && h -> inner -> type -> get_value) {
689 status = ((*(h -> inner -> type -> signal_handler))
690 (h -> inner, name, ap));
691 if (status == ISC_R_SUCCESS)
695 return ISC_R_NOTFOUND;
712 if (h -> inner && h -> inner -> type -> stuff_values) {
713 status = ((*(h -> inner -> type -> stuff_values))
714 (c, id, h -> inner));
715 if (status == ISC_R_SUCCESS)
719 return ISC_R_SUCCESS;
732 return ISC_R_SUCCESS;
738 return ISC_R_NOTIMPLEMENTED;
744 return ISC_R_NOTIMPLEMENTED;
762 if (h -> inner && h -> inner -> type -> set_value) {
763 status = ((*(h -> inner -> type -> set_value))
764 (h -> inner, id, name, value));
769 return ISC_R_NOTFOUND;
788 if (h -> inner && h -> inner -> type -> get_value) {
789 status = ((*(h -> inner -> type -> get_value))
790 (h -> inner, id, name, value));
791 if (status == ISC_R_SUCCESS)
794 return ISC_R_NOTFOUND;
825 #if defined (FAILOVER_PROTOCOL) 832 return ISC_R_SUCCESS;
849 if (h -> inner && h -> inner -> type -> get_value) {
850 status = ((*(h -> inner -> type -> signal_handler))
851 (h -> inner,
name, ap));
852 if (status == ISC_R_SUCCESS)
856 return ISC_R_NOTFOUND;
873 if (h -> inner && h -> inner -> type -> stuff_values) {
874 status = ((*(h -> inner -> type -> stuff_values))
875 (c, id, h -> inner));
876 if (status == ISC_R_SUCCESS)
880 return ISC_R_SUCCESS;
893 return ISC_R_SUCCESS;
899 return ISC_R_NOTIMPLEMENTED;
905 return ISC_R_NOTIMPLEMENTED;
#define GROUP_OBJECT_DYNAMIC
omapi_object_type_t * dhcp_type_shared_network
isc_result_t dhcp_control_remove(omapi_object_t *lp, omapi_object_t *id)
isc_result_t omapi_make_int_value(omapi_value_t **, omapi_data_string_t *, int, const char *, int)
isc_result_t omapi_object_reference(omapi_object_t **, omapi_object_t *, const char *, int)
isc_result_t end_parse(struct parse **cfile)
isc_result_t dhcp_control_set_value(omapi_object_t *h, omapi_object_t *id, omapi_data_string_t *name, omapi_typed_data_t *value)
isc_result_t dhcp_control_lookup(omapi_object_t **lp, omapi_object_t *id, omapi_object_t *ref)
#define DHCP_R_INVALIDARG
omapi_typed_data_t * value
struct group * root_group
dhcp_failover_state_t * failover_peer
isc_result_t dhcp_shared_network_set_value(omapi_object_t *h, omapi_object_t *id, omapi_data_string_t *name, omapi_typed_data_t *value)
#define DHCP_R_KEYCONFLICT
void log_fatal(const char *,...) __attribute__((__format__(__printf__
struct omapi_typed_data_t::@3::@4 buffer
isc_result_t dhcp_group_create(omapi_object_t **lp, omapi_object_t *id)
isc_result_t dhcp_group_lookup(omapi_object_t **lp, omapi_object_t *id, omapi_object_t *ref)
isc_result_t dhcp_group_destroy(omapi_object_t *h, const char *file, int line)
isc_result_t dhcp_group_remove(omapi_object_t *lp, omapi_object_t *id)
isc_result_t omapi_connection_put_uint32(omapi_object_t *, u_int32_t)
isc_result_t dhcp_control_create(omapi_object_t **lp, omapi_object_t *id)
isc_result_t dhcp_group_signal_handler(omapi_object_t *h, const char *name, va_list ap)
isc_result_t omapi_get_value_str(omapi_object_t *, omapi_object_t *, const char *, omapi_value_t **)
isc_result_t dhcp_group_set_value(omapi_object_t *h, omapi_object_t *id, omapi_data_string_t *name, omapi_typed_data_t *value)
omapi_object_type_t * dhcp_type_control
int group_dereference(struct group **ptr, const char *file, int line)
isc_result_t dhcp_subnet_create(omapi_object_t **lp, omapi_object_t *id)
int(* group_write_hook)(struct group_object *)
isc_result_t omapi_object_dereference(omapi_object_t **, const char *, int)
isc_result_t dhcp_subnet_set_value(omapi_object_t *h, omapi_object_t *id, omapi_data_string_t *name, omapi_typed_data_t *value)
isc_result_t dhcp_subnet_signal_handler(omapi_object_t *h, const char *name, va_list ap)
isc_result_t omapi_get_int_value(unsigned long *, omapi_typed_data_t *)
void dfree(void *, const char *, int)
union omapi_typed_data_t::@3 u
isc_result_t dhcp_control_destroy(omapi_object_t *h, const char *file, int line)
isc_result_t dhcp_control_stuff_values(omapi_object_t *c, omapi_object_t *id, omapi_object_t *h)
isc_result_t omapi_handle_td_lookup(omapi_object_t **, omapi_typed_data_t *)
isc_result_t dhcp_group_stuff_values(omapi_object_t *c, omapi_object_t *id, omapi_object_t *h)
isc_result_t dhcp_shared_network_destroy(omapi_object_t *h, const char *file, int line)
isc_result_t dhcp_control_get_value(omapi_object_t *h, omapi_object_t *id, omapi_data_string_t *name, omapi_value_t **value)
#define GROUP_OBJECT_DELETED
void * dmalloc(size_t, const char *, int)
isc_result_t dhcp_shared_network_get_value(omapi_object_t *h, omapi_object_t *id, omapi_data_string_t *name, omapi_value_t **value)
isc_result_t dhcp_subnet_get_value(omapi_object_t *h, omapi_object_t *id, omapi_data_string_t *name, omapi_value_t **value)
isc_result_t omapi_connection_put_string(omapi_object_t *, const char *)
struct subnet * next_subnet
omapi_object_type_t * dhcp_type_group
dhcp_control_object_t * dhcp_control_object
isc_result_t dhcp_subnet_destroy(omapi_object_t *h, const char *file, int line)
isc_result_t omapi_value_dereference(omapi_value_t **, const char *, int)
isc_result_t omapi_object_type_register(omapi_object_type_t **, const char *, isc_result_t(*)(omapi_object_t *, omapi_object_t *, omapi_data_string_t *, omapi_typed_data_t *), isc_result_t(*)(omapi_object_t *, omapi_object_t *, omapi_data_string_t *, omapi_value_t **), isc_result_t(*)(omapi_object_t *, const char *, int), isc_result_t(*)(omapi_object_t *, const char *, va_list), isc_result_t(*)(omapi_object_t *, omapi_object_t *, omapi_object_t *), isc_result_t(*)(omapi_object_t **, omapi_object_t *, omapi_object_t *), isc_result_t(*)(omapi_object_t **, omapi_object_t *), isc_result_t(*)(omapi_object_t *, omapi_object_t *), isc_result_t(*)(omapi_object_t *, const char *, int), isc_result_t(*)(omapi_object_t **, const char *, int), isc_result_t(*)(size_t), size_t, isc_result_t(*)(omapi_object_t *, const char *, int), int)
isc_result_t dhcp_shared_network_remove(omapi_object_t *lp, omapi_object_t *id)
isc_result_t dhcp_subnet_stuff_values(omapi_object_t *c, omapi_object_t *id, omapi_object_t *h)
isc_result_t dhcp_subnet_remove(omapi_object_t *lp, omapi_object_t *id)
isc_result_t dhcp_subnet_lookup(omapi_object_t **lp, omapi_object_t *id, omapi_object_t *ref)
int omapi_ds_strcmp(omapi_data_string_t *, const char *)
isc_result_t supersede_group(struct group_object *group, int writep)
struct subnet * next_sibling
isc_result_t dhcp_shared_network_signal_handler(omapi_object_t *h, const char *name, va_list ap)
struct interface_info * interface
isc_result_t interface_setup()
isc_result_t dhcp_group_get_value(omapi_object_t *h, omapi_object_t *id, omapi_data_string_t *name, omapi_value_t **value)
group_hash_t * group_name_hash
isc_result_t dhcp_shared_network_create(omapi_object_t **lp, omapi_object_t *id)
isc_result_t dhcp_shared_network_stuff_values(omapi_object_t *c, omapi_object_t *id, omapi_object_t *h)
struct ipv6_pool ** pools
struct shared_network * next
isc_result_t omapi_connection_put_name(omapi_object_t *, const char *)
isc_result_t dhcp_set_control_state(control_object_state_t oldstate, control_object_state_t newstate)
int parse_executable_statements(struct executable_statement **statements, struct parse *cfile, int *lose, enum expression_context case_context)
void dhcp_common_objects_setup(void)
isc_result_t dhcp_shared_network_lookup(omapi_object_t **lp, omapi_object_t *id, omapi_object_t *ref)
int clone_group(struct group **gp, struct group *group, const char *file, int line)
OMAPI_OBJECT_ALLOC(shared_network, struct shared_network, omapi_object_type_t *dhcp_type_shared_network)
struct interface_info * interface
isc_result_t new_parse(struct parse **cfile, int file, char *inbuf, unsigned buflen, const char *name, int eolp)
omapi_object_type_t * dhcp_type_subnet
isc_result_t dhcp_control_signal_handler(omapi_object_t *h, const char *name, va_list ap)
isc_result_t omapi_make_string_value(omapi_value_t **, omapi_data_string_t *, const char *, const char *, int)