M deps/cflag/cflag.h => deps/cflag/cflag.h +2 -2
@@ 40,13 40,13 @@ struct cflag {
#define CFLAG(_t, _name, _letter, _data, _help) \
- { \
+ ((struct cflag) { \
.func = cflag_ ## _t, \
.name = (_name), \
.letter = (_letter), \
.data = (_data), \
.help = (_help), \
- }
+ })
#define CFLAG_HELP \
CFLAG(help, "help", 'h', NULL, "Prints command line usage help.")
#define CFLAG_END \
M deps/dbuf/dbuf.c => deps/dbuf/dbuf.c +1 -1
@@ 57,7 57,7 @@ struct dbuf*
dbuf_new(size_t prealloc)
{
struct dbuf *b = mrealloc(NULL, sizeof(struct dbuf));
- *b = (struct dbuf)DBUF_INIT;
+ *b = DBUF_INIT;
bresize(b, prealloc);
return b;
}
M deps/dbuf/dbuf.h => deps/dbuf/dbuf.h +1 -1
@@ 24,7 24,7 @@ struct dbuf {
size_t alloc;
};
-#define DBUF_INIT { .data = NULL, .size = 0, .alloc = 0 }
+#define DBUF_INIT ((struct dbuf) { .data = NULL, .size = 0, .alloc = 0 })
struct dbuf* dbuf_new(size_t prealloc)
__attribute__((warn_unused_result));