From 1b9d3964f5ef69f84a603726d0c8f554dbd448c4 Mon Sep 17 00:00:00 2001 From: Chun-wei Fan Date: Tue, 1 Oct 2024 17:14:41 +0800 Subject: [PATCH] gvariant-core.c: Fix suffix alignment on 32-bit MSVC builds With a similar rationale to commit d50102f2, this avoids the static assert from failing on 32-bit Visual Studio builds. --- glib/gvariant-core.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/glib/gvariant-core.c b/glib/gvariant-core.c index 7afef1b2f..f530fa311 100644 --- a/glib/gvariant-core.c +++ b/glib/gvariant-core.c @@ -78,6 +78,8 @@ struct _GVariant #if g_macro__has_attribute(aligned) guint8 suffix[] __attribute__((aligned(8))); +#elif defined _MSC_VER + __declspec(align (8)) guint8 suffix[]; #else guint8 suffix[]; #endif