mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-30 00:00:11 +01:00
Workaround for GCC bug
Signed-off-by: Steffen Vogel <post@steffenvogel.de>
This commit is contained in:
parent
624b4fe2f7
commit
0c75b25662
1 changed files with 4 additions and 0 deletions
|
@ -26,7 +26,11 @@ Test(buffer, decode) {
|
||||||
const char *e = "{\"id\": \"5a786626-fbc6-4c04-98c2-48027e68c2fa\"}";
|
const char *e = "{\"id\": \"5a786626-fbc6-4c04-98c2-48027e68c2fa\"}";
|
||||||
size_t len = strlen(e);
|
size_t len = strlen(e);
|
||||||
|
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
// Workaround for compiler bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106199
|
||||||
|
#pragma GCC diagnostic ignored "-Wstringop-overflow"
|
||||||
buf.insert(buf.begin(), e, e + len);
|
buf.insert(buf.begin(), e, e + len);
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
|
||||||
k = json_loads(e, 0, nullptr);
|
k = json_loads(e, 0, nullptr);
|
||||||
cr_assert_not_null(k);
|
cr_assert_not_null(k);
|
||||||
|
|
Loading…
Add table
Reference in a new issue