summaryrefslogtreecommitdiff
path: root/omapip/support.c
diff options
context:
space:
mode:
authorTed Lemon <source@isc.org>2000-05-01 23:52:05 +0000
committerTed Lemon <source@isc.org>2000-05-01 23:52:05 +0000
commite598929f6d359d2bae5ddacc9b8cdc6b3fe31550 (patch)
treeae3d050c3cf5c97c7afaf956b26124aa686ad12a /omapip/support.c
parent85e9641dc8d9a20db62b40263fafe0ff1a297b88 (diff)
downloadisc-dhcp-e598929f6d359d2bae5ddacc9b8cdc6b3fe31550.tar.gz
Fix a stupid pasto in make_int_value. Add make_uint_value.
Diffstat (limited to 'omapip/support.c')
-rw-r--r--omapip/support.c22
1 files changed, 14 insertions, 8 deletions
diff --git a/omapip/support.c b/omapip/support.c
index 370427e7..99f449b9 100644
--- a/omapip/support.c
+++ b/omapip/support.c
@@ -608,18 +608,24 @@ isc_result_t omapi_make_int_value (omapi_value_t **vp,
omapi_value_dereference (vp, file, line);
return status;
}
- if (value) {
- status = omapi_typed_data_new (file, line, &(*vp) -> value,
- omapi_datatype_int);
- if (status != ISC_R_SUCCESS) {
- omapi_value_dereference (vp, file, line);
- return status;
- }
- (*vp) -> value -> u.integer = value;
+ status = omapi_typed_data_new (file, line, &(*vp) -> value,
+ omapi_datatype_int);
+ if (status != ISC_R_SUCCESS) {
+ omapi_value_dereference (vp, file, line);
+ return status;
}
+ (*vp) -> value -> u.integer = value;
return ISC_R_SUCCESS;
}
+isc_result_t omapi_make_uint_value (omapi_value_t **vp,
+ omapi_data_string_t *name,
+ unsigned int value,
+ const char *file, int line)
+{
+ return omapi_make_int_value (vp, name, (int)value, file, line);
+}
+
isc_result_t omapi_make_handle_value (omapi_value_t **vp,
omapi_data_string_t *name,
omapi_object_t *value,