]> git.sur5r.net Git - bacula/bacula/blobdiff - bacula/src/lib/dlist.h
Fix problem of accents with new Win32 code.
[bacula/bacula] / bacula / src / lib / dlist.h
index ce975f486593d27e729eaac27bf435274228d289..32933ad608518254b7205dc94949e0dc3736be86 100644 (file)
  *
  * Loop var through each member of list
  */
+#ifdef HAVE_GCC
 #define foreach_dlist(var, list) \
-    for((var)=NULL; (*((void **)&(var))=(void*)((list)->next(var))); )
-
-#ifdef the_old_way
+        for((var)=NULL; ((var)=(typeof(var))(list)->next(var)); )
+#else
 #define foreach_dlist(var, list) \
-        for((var)=NULL; (((void *)(var))=(list)->next(var)); )
+    for((var)=NULL; (*((void **)&(var))=(void*)((list)->next(var))); )
 #endif
 
 
+
 struct dlink {
    void *next;
    void *prev;