From: Vincent Bernat Date: Tue, 15 Dec 2015 09:38:34 +0000 (+0100) Subject: client: avoid -Waddress warning by comparing to NULL X-Git-Tag: 0.8.0~16 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=5ed4156c02b0ba801feb9bf383d9b7772dc990e5;p=thirdparty%2Flldpd.git client: avoid -Waddress warning by comparing to NULL --- diff --git a/src/client/writer.h b/src/client/writer.h index ea2d4cff..18737801 100644 --- a/src/client/writer.h +++ b/src/client/writer.h @@ -33,7 +33,7 @@ struct writer { #define tag_attr(w,...) w->attr(w,## __VA_ARGS__) #define tag_data(w,...) w->data(w,## __VA_ARGS__) #define tag_end(w,...) w->end(w,## __VA_ARGS__) -#define tag_datatag(w,t,d,v) do { if (!(v)) break; w->start(w,t,d); w->data(w,v); w->end(w); } while(0); +#define tag_datatag(w,t,d,v) do { if ((v) != NULL) break; w->start(w,t,d); w->data(w,v); w->end(w); } while(0); extern struct writer * txt_init( FILE * ); extern struct writer * kv_init( FILE * );