Parcourir la source

[IA64] Low byte of current->personality is not a bitmask.

Peter Staubach pointed out that it is not correct to check
current->personality & PER_LINUX32 (this will have false
hits on several other personality values).

Signed-off-by: Tony Luck <tony.luck@intel.com>
Tony Luck il y a 20 ans
Parent
commit
ff67b59726
1 fichiers modifiés avec 2 ajouts et 1 suppressions
  1. 2 1
      include/asm-ia64/fcntl.h

+ 2 - 1
include/asm-ia64/fcntl.h

@@ -81,6 +81,7 @@ struct flock {
 
 
 #define F_LINUX_SPECIFIC_BASE	1024
 #define F_LINUX_SPECIFIC_BASE	1024
 
 
-#define force_o_largefile() ( ! (current->personality & PER_LINUX32) )
+#define force_o_largefile()	\
+		(personality(current->personality) != PER_LINUX32)
 
 
 #endif /* _ASM_IA64_FCNTL_H */
 #endif /* _ASM_IA64_FCNTL_H */