From 050945e949135c1b98ed353fc05fcf9b8c1587bd Mon Sep 17 00:00:00 2001 From: Marc Dionne Date: Sat, 14 May 2011 13:19:52 -0400 Subject: [PATCH] Linux: fix permission op test for certain compilers Some compilers complain that _inode is used uninitialised here. Since this test requires -Werror, it causes the test to fail and our permission op to be used in RCU mode, leading to lockups. Initialise it to make the compilers happy. Fixes a lockup seen on kernels 2.6.38+ on Gentoo and Debian. Change-Id: Id6325e3a5a918906d547d241a39de777fb394fdc Reviewed-on: http://gerrit.openafs.org/4654 Tested-by: BuildBot Reviewed-by: Derrick Brashear --- src/cf/linux-test4.m4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cf/linux-test4.m4 b/src/cf/linux-test4.m4 index 9390489..efe1b5a 100644 --- a/src/cf/linux-test4.m4 +++ b/src/cf/linux-test4.m4 @@ -248,7 +248,7 @@ AC_DEFUN([LINUX_IOP_I_PERMISSION_TAKES_FLAGS], [ AC_CHECK_LINUX_BUILD([whether inode_operations.permission takes flags], [ac_cv_linux_func_i_permission_takes_flags], [#include ], - [struct inode _inode; + [struct inode _inode = {0}; unsigned int flags = 0; (void)_inode.i_op->permission(&_inode, 0, flags);], [IOP_PERMISSION_TAKES_FLAGS], -- 1.9.4