Import readline 7.0 (patch 5)
[deliverable/binutils-gdb.git] / readline / xfree.c
index 37a81e6c236cbd2d4e8f12951cf32ef8b1942410..d3af7d9aef0b9a420dc9d50faaf6041ab9b016f4 100644 (file)
 #  include "ansi_stdlib.h"
 #endif /* HAVE_STDLIB_H */
 
+#include <stdio.h>
+
 #include "xmalloc.h"
+#include "readline.h"
 
 /* **************************************************************** */
 /*                                                                 */
@@ -45,6 +48,10 @@ void
 xfree (string)
      PTR_T string;
 {
+  /* Leak a bit.  */
+  if (RL_ISSTATE(RL_STATE_SIGHANDLER))
+    return;
+
   if (string)
     free (string);
 }
This page took 0.02251 seconds and 4 git commands to generate.