From: Chanwoo Choi Date: Mon, 4 Jul 2022 18:53:39 +0000 (+0900) Subject: util: kernel: Remove unused variable to fix build warning X-Git-Tag: accepted/tizen/unified/20220707.133338^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3393781e7dd5e19df1205bc8512fe84a8c1dbcf8;p=platform%2Fcore%2Fsystem%2Fpass.git util: kernel: Remove unused variable to fix build warning Fix the following warning. /home/abuild/rpmbuild/BUILD/pass-1.2.0/src/util/kernel.c: In function 'get_gpu_mem_info': /home/abuild/rpmbuild/BUILD/pass-1.2.0/src/util/kernel.c:435:6: warning: variable 'n' set but not used [-Wunused-but-set-variable] | int n; Change-Id: Ie763f9bf4f2aa61aa22535ca0209871359306419 Signed-off-by: Chanwoo Choi --- diff --git a/src/util/kernel.c b/src/util/kernel.c index 2b60f3e..e714c6a 100644 --- a/src/util/kernel.c +++ b/src/util/kernel.c @@ -432,10 +432,9 @@ get_gpu_mem_info(struct proc_map_info *map_info, FILE *smaps_fd, char *entry) struct gpu_mem_node *gnode = NULL; char name[BUFF_MAX]; char buffer[BUFF_MAX]; - int n; new_entry: - n = sscanf(entry, "%*s %*s %*s %*s %*s %[^\n]", name); + sscanf(entry, "%*s %*s %*s %*s %*s %[^\n]", name); gnode = get_gpu_mem_node(name); if (gnode) {