summaryrefslogtreecommitdiff
path: root/lib/urlapi.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2020-12-26 16:39:20 +0100
committerDaniel Stenberg <daniel@haxx.se>2020-12-26 16:39:20 +0100
commit1557829c6c69f481d8d5b2cfb92cfab3d3f80dd4 (patch)
tree95a386bd03f184806d6d43e98fda86c91e6d52b7 /lib/urlapi.c
parent6b4c9b8ae0f6283ed8282d56222dd42c119a14a3 (diff)
downloadcurl-bagder/aws-macro-warning.tar.gz
fixup more empty expressions fixedbagder/aws-macro-warning
Diffstat (limited to 'lib/urlapi.c')
-rw-r--r--lib/urlapi.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/lib/urlapi.c b/lib/urlapi.c
index ae7596359..e3a788221 100644
--- a/lib/urlapi.c
+++ b/lib/urlapi.c
@@ -983,12 +983,14 @@ void curl_url_cleanup(CURLU *u)
}
}
-#define DUP(dest, src, name) \
- if(src->name) { \
- dest->name = strdup(src->name); \
- if(!dest->name) \
- goto fail; \
- }
+#define DUP(dest, src, name) \
+ do { \
+ if(src->name) { \
+ dest->name = strdup(src->name); \
+ if(!dest->name) \
+ goto fail; \
+ } \
+ } while(0)
CURLU *curl_url_dup(CURLU *in)
{