]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Make iter for DECLARE_TYPED_DIGESTMAP_FNS be a pointer.
authorNick Mathewson <nickm@torproject.org>
Tue, 2 Sep 2014 19:40:04 +0000 (15:40 -0400)
committerNick Mathewson <nickm@torproject.org>
Tue, 2 Sep 2014 19:40:04 +0000 (15:40 -0400)
This fixes a clangalyzer warning, and makes our C slightly better C.

src/common/container.h

index 9fb4cf334c110ab2d7fa6098205bf5c302eaefb8..26ac85120d745a56263b9ac24b4b27552ce3d787 100644 (file)
@@ -473,7 +473,7 @@ void* strmap_remove_lc(strmap_t *map, const char *key);
 
 #define DECLARE_TYPED_DIGESTMAP_FNS(prefix, maptype, valtype)           \
   typedef struct maptype maptype;                                       \
-  typedef struct prefix##iter_t prefix##iter_t;                         \
+  typedef struct prefix##iter_t *prefix##iter_t;                        \
   ATTR_UNUSED static INLINE maptype*                                    \
   prefix##new(void)                                                     \
   {                                                                     \