diff options
author | Alex Richardson <arichardson@FreeBSD.org> | 2022-12-14 23:55:18 +0000 |
---|---|---|
committer | Alex Richardson <arichardson@FreeBSD.org> | 2023-02-10 18:22:20 +0000 |
commit | 2aed76fc944dc9c4517ec1f9209c39d9a1ae78e4 (patch) | |
tree | cc5498a3b5a11921b7ed655fd2caa817c9896438 | |
parent | 702e606f7397d046f588d20894456b4c2cfbd1dd (diff) | |
download | glib-2aed76fc944dc9c4517ec1f9209c39d9a1ae78e4.tar.gz |
Fix GHashTableIter layout for CHERI targets
Last field needs to be pointer-size to match GHashTableIter. This happened
to work for most architecture due to alignment padding/pointer size, but
for CHERI targets with 128-bit pointers RealIter ends up being smaller
than GHashTableIter.
Helps: https://gitlab.gnome.org/GNOME/glib/-/issues/2842
-rw-r--r-- | glib/ghash.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/glib/ghash.c b/glib/ghash.c index 132e3ac5e..eafb37bb3 100644 --- a/glib/ghash.c +++ b/glib/ghash.c @@ -292,7 +292,7 @@ typedef struct gpointer dummy2; gint position; gboolean dummy3; - gint version; + gintptr version; } RealIter; G_STATIC_ASSERT (sizeof (GHashTableIter) == sizeof (RealIter)); |