From 418c8e4ee3dc3b6257b8b12ae8f57296bb6369a1 Mon Sep 17 00:00:00 2001 From: John Beard Date: Thu, 20 Aug 2015 12:32:05 +0100 Subject: [PATCH] Fix compilation error for kernel version codes < 3.0.0 This was caused by the flags variable being declared only if the version is >= 3.0.0 and < 3.7.0 (where it is no longer need) --- exfat_super.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/exfat_super.c b/exfat_super.c index f2c70a367eb16c..dde80559a5cf09 100644 --- a/exfat_super.c +++ b/exfat_super.c @@ -294,14 +294,14 @@ static int exfat_revalidate_ci(struct dentry *dentry, struct nameidata *nd) #if LINUX_VERSION_CODE >= KERNEL_VERSION(3,7,00) if (flags & LOOKUP_RCU) return -ECHILD; -#elif LINUX_VERSION_CODE >= KERNEL_VERSION(3,0,00) +#else unsigned int flags; +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,0,00) if (nd && nd->flags & LOOKUP_RCU) return -ECHILD; +#endif - flags = nd ? nd->flags : 0; -#else flags = nd ? nd->flags : 0; #endif