diff --git a/src/dict.c b/src/dict.c
index ba574c8..9f741a2 100644
--- a/src/dict.c
+++ b/src/dict.c
@@ -104,6 +104,9 @@
     str1 = ((struct ly_dict_rec *)val1_p)->value;
     str2 = ((struct ly_dict_rec *)val2_p)->value;
 
+    LY_CHECK_ERR_RET(!str1, LOGARG(NULL, val1_p), 0);
+    LY_CHECK_ERR_RET(!str2, LOGARG(NULL, val2_p), 0);
+
     if (mod) {
         /* used when inserting new values */
         if (strcmp(str1, str2) == 0) {
@@ -174,7 +177,7 @@
     return ret;
 }
 
-static LY_ERR
+LY_ERR
 dict_insert(const struct ly_ctx *ctx, char *value, size_t len, ly_bool zerocopy, const char **str_p)
 {
     LY_ERR ret = LY_SUCCESS;
@@ -218,7 +221,9 @@
         return ret;
     }
 
-    *str_p = match->value;
+    if (str_p) {
+        *str_p = match->value;
+    }
 
     return ret;
 }
@@ -264,49 +269,3 @@
 
     return result;
 }
-
-static LY_ERR
-dict_dup(const struct ly_ctx *ctx, char *value, const char **str_p)
-{
-    LY_ERR ret = LY_SUCCESS;
-    struct ly_dict_rec *match = NULL, rec;
-    uint32_t hash;
-
-    /* set new callback to only compare memory addresses */
-    lyht_value_equal_cb prev = lyht_set_cb(ctx->dict.hash_tab, lydict_resize_val_eq);
-
-    LOGDBG(LY_LDGDICT, "duplicating %s", value);
-    hash = lyht_hash(value, strlen(value));
-    rec.value = value;
-
-    ret = lyht_find(ctx->dict.hash_tab, (void *)&rec, hash, (void **)&match);
-    if (ret == LY_SUCCESS) {
-        /* record found, increase refcount */
-        match->refcount++;
-        *str_p = match->value;
-    }
-
-    /* restore callback */
-    lyht_set_cb(ctx->dict.hash_tab, prev);
-
-    return ret;
-}
-
-LIBYANG_API_DEF LY_ERR
-lydict_dup(const struct ly_ctx *ctx, const char *value, const char **str_p)
-{
-    LY_ERR result;
-
-    LY_CHECK_ARG_RET(ctx, ctx, str_p, LY_EINVAL);
-
-    if (!value) {
-        *str_p = NULL;
-        return LY_SUCCESS;
-    }
-
-    pthread_mutex_lock((pthread_mutex_t *)&ctx->dict.lock);
-    result = dict_dup(ctx, (char *)value, str_p);
-    pthread_mutex_unlock((pthread_mutex_t *)&ctx->dict.lock);
-
-    return result;
-}
