ipv6: fib: fix crash when changing large fib while dumping it
[safe/jmp/linux-2.6] / include / linux / personality.h
index bf4cf20..1261208 100644 (file)
@@ -40,7 +40,10 @@ enum {
  * Security-relevant compatibility flags that must be
  * cleared upon setuid or setgid exec:
  */
-#define PER_CLEAR_ON_SETID (READ_IMPLIES_EXEC|ADDR_NO_RANDOMIZE)
+#define PER_CLEAR_ON_SETID (READ_IMPLIES_EXEC  | \
+                           ADDR_NO_RANDOMIZE  | \
+                           ADDR_COMPAT_LAYOUT | \
+                           MMAP_PAGE_ZERO)
 
 /*
  * Personality types.
@@ -105,16 +108,12 @@ struct exec_domain {
  */
 #define personality(pers)      (pers & PER_MASK)
 
-/*
- * Personality of the currently running process.
- */
-#define get_personality                (current->personality)
 
 /*
  * Change personality of the currently running process.
  */
 #define set_personality(pers) \
-       ((current->personality == pers) ? 0 : __set_personality(pers))
+       ((current->personality == (pers)) ? 0 : __set_personality(pers))
 
 #endif /* __KERNEL__ */