summaryrefslogtreecommitdiff
path: root/source3/lib
diff options
context:
space:
mode:
Diffstat (limited to 'source3/lib')
-rw-r--r--source3/lib/dbwrap_util.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/source3/lib/dbwrap_util.c b/source3/lib/dbwrap_util.c
index aca4b52697..154bf6b553 100644
--- a/source3/lib/dbwrap_util.c
+++ b/source3/lib/dbwrap_util.c
@@ -356,3 +356,20 @@ NTSTATUS dbwrap_delete_bystring_upper(struct db_context *db, const char *key)
talloc_free(key_upper);
return status;
}
+
+NTSTATUS dbwrap_store_bystring_upper(struct db_context *db, const char *key,
+ TDB_DATA data, int flags)
+{
+ char *key_upper;
+ NTSTATUS status;
+
+ key_upper = talloc_strdup_upper(talloc_tos(), key);
+ if (key_upper == NULL) {
+ return NT_STATUS_NO_MEMORY;
+ }
+
+ status = dbwrap_store_bystring(db, key_upper, data, flags);
+
+ talloc_free(key_upper);
+ return status;
+}