diff --git a/sql/mysqld.cc b/sql/mysqld.cc index 4d6aaa7e51a..698d5c1d690 100644 --- a/sql/mysqld.cc +++ b/sql/mysqld.cc @@ -65,6 +65,12 @@ #define ONE_THREAD #endif +#ifdef HAVE_purify +#define IF_PURIFY(A,B) (A) +#else +#define IF_PURIFY(A,B) (B) +#endif + #if SIZEOF_CHARP == 4 #define MAX_MEM_TABLE_SIZE ~(ulong) 0 #else @@ -5680,7 +5686,7 @@ log and this option does nothing anymore.", #endif {"symbolic-links", 's', "Enable symbolic link support.", (gptr*) &my_use_symdir, (gptr*) &my_use_symdir, 0, GET_BOOL, NO_ARG, - 1, 0, 0, 0, 0, 0}, + IF_PURIFY(0,1), 0, 0, 0, 0, 0}, {"sysdate-is-now", OPT_SYSDATE_IS_NOW, "Non-default option to alias SYSDATE() to NOW() to make it safe-replicable. Since 5.0, SYSDATE() returns a `dynamic' value different for different invocations, even within the same statement.", (gptr*) &global_system_variables.sysdate_is_now, @@ -5712,7 +5718,12 @@ log and this option does nothing anymore.", 0, 0, 0, 0, 0}, {"use-symbolic-links", 's', "Enable symbolic link support. Deprecated option; use --symbolic-links instead.", (gptr*) &my_use_symdir, (gptr*) &my_use_symdir, 0, GET_BOOL, NO_ARG, - 1, 0, 0, 0, 0, 0}, + /* + The system call realpath() produces warnings under valgrind and + purify. These are not suppressed: instead we disable symlinks + option if compiled with valgrind support. + */ + IF_PURIFY(0,1), 0, 0, 0, 0, 0}, {"user", 'u', "Run mysqld daemon as user.", 0, 0, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, {"verbose", 'v', "Used with --help option for detailed help",