]> git.droids-corp.org - dpdk.git/blobdiff - lib/librte_hash/rte_fbk_hash.c
replace snprintf with strlcpy without adding extra include
[dpdk.git] / lib / librte_hash / rte_fbk_hash.c
index c9b470d7e20be527c5acae3f30f4870bcca569e3..9360f79818a378d74275bf9b9e9a1b50be773958 100644 (file)
@@ -141,7 +141,7 @@ rte_fbk_hash_create(const struct rte_fbk_hash_params *params)
 #endif
 
        /* Set up hash table context. */
-       snprintf(ht->name, sizeof(ht->name), "%s", params->name);
+       strlcpy(ht->name, params->name, sizeof(ht->name));
        ht->entries = params->entries;
        ht->entries_per_bucket = params->entries_per_bucket;
        ht->used_entries = 0;