summaryrefslogtreecommitdiff
path: root/omapip
diff options
context:
space:
mode:
authorShawn Routhier <sar@isc.org>2013-06-05 18:15:49 -0700
committerShawn Routhier <sar@isc.org>2013-06-05 18:15:49 -0700
commit08b2d347838a79446aea6a57e679d3c8b1e8f663 (patch)
tree71691c319c6b63f997c0f3c4050399a0d030b513 /omapip
parent360cc6d99356fcf2d2368193607f8c7032dac8da (diff)
downloadisc-dhcp-08b2d347838a79446aea6a57e679d3c8b1e8f663.tar.gz
[master]
Modify the class and subclass code to allow for dynamic addition and removal of subclasses. See 27452 for details.
Diffstat (limited to 'omapip')
-rw-r--r--omapip/buffer.c21
1 files changed, 20 insertions, 1 deletions
diff --git a/omapip/buffer.c b/omapip/buffer.c
index 4104cfb7..518f6d37 100644
--- a/omapip/buffer.c
+++ b/omapip/buffer.c
@@ -3,7 +3,7 @@
Buffer access functions for the object management protocol... */
/*
- * Copyright (c) 2009,2012 by Internet Systems Consortium, Inc. ("ISC")
+ * Copyright (c) 2009,2012-2013 by Internet Systems Consortium, Inc. ("ISC")
* Copyright (c) 2004,2005,2007 by Internet Systems Consortium, Inc. ("ISC")
* Copyright (c) 1999-2003 by Internet Software Consortium
*
@@ -720,3 +720,22 @@ isc_result_t omapi_connection_put_handle (omapi_object_t *c, omapi_object_t *h)
return status;
return omapi_connection_put_uint32 (c, handle);
}
+
+isc_result_t omapi_connection_put_named_uint32 (omapi_object_t *c,
+ const char *name,
+ u_int32_t value)
+{
+ isc_result_t status;
+
+ status = omapi_connection_put_name(c, name);
+ if (status != ISC_R_SUCCESS)
+ return (status);
+
+ status = omapi_connection_put_uint32(c, sizeof(u_int32_t));
+ if (status != ISC_R_SUCCESS)
+ return (status);
+
+ status = omapi_connection_put_uint32(c, value);
+ return (status);
+}
+