]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Changed safe_free() definition to eliminate multiple "ambiguous else" warnings.
authorAlex Rousskov <rousskov@measurement-factory.com>
Mon, 1 Nov 2010 20:45:08 +0000 (14:45 -0600)
committerAlex Rousskov <rousskov@measurement-factory.com>
Mon, 1 Nov 2010 20:45:08 +0000 (14:45 -0600)
compat/xalloc.h

index 14cb5dd65e1ea768f35dc77a372cc97a9f2330e1..084c5225227a54f18682d3b9604c97a4c1c95c00 100644 (file)
@@ -60,7 +60,7 @@ void free_const(const void *s);
  * Define failure_notify to receive error message.
  * otherwise perror() is used to display it.
  */
-#define safe_free(x)    if ((x)) { xxfree((x)); (x) = NULL; } else (void)0
+#define safe_free(x)    while (x) { xxfree(x); (x) = NULL; }
 
 
 #if XMALLOC_STATISTICS