Skip to content
Snippets Groups Projects
Commit 174875d6 authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Use the do/while(0) trick to eliminate warnings w/use of SAEFCOPY_UTF8

parent af0a37a8
No related branches found
No related tags found
No related merge requests found
Pipeline #5813 passed
......@@ -266,7 +266,7 @@ extern int thread_suid_broken; /* NPTL is no longer broken */
#include "xpdatetime.h"
#include "unicode_defs.h"
#define SAFECOPY_UTF8(dst, src) if(utf8_str_is_valid(src)) utf8_strlcpy(dst, src, sizeof dst); else SAFECOPY(dst, src)
#define SAFECOPY_UTF8(dst, src) do { if(utf8_str_is_valid(src)) utf8_strlcpy(dst, src, sizeof dst); else SAFECOPY(dst, src); } while(0)
/***********************/
/* Synchronet-specific */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment