]> git.droids-corp.org - dpdk.git/commitdiff
eal/linux: remove useless memset
authorStephen Hemminger <stephen@networkplumber.org>
Sat, 14 Feb 2015 14:59:09 +0000 (09:59 -0500)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Wed, 4 Mar 2015 20:50:42 +0000 (21:50 +0100)
The path variable is set via snprintf, and does not need to
memset before that.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
lib/librte_eal/linuxapp/eal/eal_hugepage_info.c

index 590cb5659151c104a7c7ded4d03139d781c5e829..8d29e06c90607e4fa467d392b9918c3e7f2aa545 100644 (file)
@@ -84,8 +84,6 @@ get_num_hugepages(const char *subdir)
        else
                nr_hp_file = "free_hugepages";
 
-       memset(path, 0, sizeof(path));
-
        snprintf(path, sizeof(path), "%s/%s/%s",
                        sys_dir_path, subdir, nr_hp_file);