Index: trunk/src/sh_files.c
===================================================================
--- trunk/src/sh_files.c	(revision 463)
+++ trunk/src/sh_files.c	(revision 465)
@@ -589,4 +589,7 @@
   return zAVL_string_get (fileTree, path);
 }
+
+static void * sh_dummy_candidate;
+
 static char * intern_find_morespecific_dir(zAVLTree * tree, 
 					   const char * path, size_t * len)
@@ -601,4 +604,6 @@
   if (NULL == tree)
     return NULL;
+
+  sh_dummy_candidate = (void *) &candidate;
 
   SH_MUTEX_LOCK(mutex_zfiles);
Index: trunk/src/sh_inotify.c
===================================================================
--- trunk/src/sh_inotify.c	(revision 463)
+++ trunk/src/sh_inotify.c	(revision 465)
@@ -21,4 +21,10 @@
 
 #if defined(HAVE_SYS_INOTIFY_H)
+
+#if defined(GCC_VERSION_MAJOR)
+#if (GCC_VERSION_MAJOR > 4) || ((GCC_VERSION_MAJOR == 4) && (GCC_VERSION_MINOR > 8))
+#pragma GCC diagnostic ignored "-Wclobbered"
+#endif
+#endif
 
 #undef  FIL__
Index: trunk/src/sh_nmail.c
===================================================================
--- trunk/src/sh_nmail.c	(revision 463)
+++ trunk/src/sh_nmail.c	(revision 465)
@@ -22,4 +22,10 @@
 #if defined(HAVE_PTHREAD_MUTEX_RECURSIVE)
 #define _XOPEN_SOURCE 500
+#endif
+
+#if defined(GCC_VERSION_MAJOR)
+#if (GCC_VERSION_MAJOR > 4) || ((GCC_VERSION_MAJOR == 4) && (GCC_VERSION_MINOR > 8))
+#pragma GCC diagnostic ignored "-Wclobbered"
+#endif
 #endif
 
Index: trunk/src/zAVLTree.c
===================================================================
--- trunk/src/zAVLTree.c	(revision 463)
+++ trunk/src/zAVLTree.c	(revision 465)
@@ -39,9 +39,14 @@
   return (zAVLKey) arg;
 }
+static char * dummy_zfree_string;
 static void zfree_string (void * inptr)
 {
   char * str = (char *) inptr;
+
+  /* Take the address to circumvent gcc 4.9 optimizer bug */
+  dummy_zfree_string = (char *) &inptr;
+
   str[0] = '\0';
-  free (str);
+  free (inptr);
   return;
 }
