lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1576761291-30121-1-git-send-email-yangtiezhu@loongson.cn>
Date:   Thu, 19 Dec 2019 21:14:51 +0800
From:   Tiezhu Yang <yangtiezhu@...ngson.cn>
To:     David Howells <dhowells@...hat.com>
Cc:     linux-afs@...ts.infradead.org, linux-kernel@...r.kernel.org
Subject: [PATCH] afs: Fix compile warning in afs_dynroot_lookup()

Fix the following compile warning:

  CC      fs/afs/dynroot.o
fs/afs/dynroot.c: In function ‘afs_dynroot_lookup’:
fs/afs/dynroot.c:117:6: warning: ‘len’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  ret = lookup_one_len(name, dentry->d_parent, len);
      ^
fs/afs/dynroot.c:91:6: note: ‘len’ was declared here
  int len;
      ^

Signed-off-by: Tiezhu Yang <yangtiezhu@...ngson.cn>
---
 fs/afs/dynroot.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/afs/dynroot.c b/fs/afs/dynroot.c
index 7503899..303f712 100644
--- a/fs/afs/dynroot.c
+++ b/fs/afs/dynroot.c
@@ -88,7 +88,7 @@ static struct dentry *afs_lookup_atcell(struct dentry *dentry)
 	struct dentry *ret;
 	unsigned int seq = 0;
 	char *name;
-	int len;
+	int len = 0;
 
 	if (!net->ws_cell)
 		return ERR_PTR(-ENOENT);
-- 
2.1.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ