From b15828e1195d606daf7c8b227aadffaf891a3a52 Mon Sep 17 00:00:00 2001 From: "Owen W. Taylor" Date: Tue, 16 Jun 2026 15:55:18 -0400 Subject: [PATCH] Fix crash on image indexes with missing architecture It's legitimate to have manifests listed in an image index that have no platform object, and hence no architecture - avoid crashing if we encounter such a manifest. --- common/flatpak-json-oci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/flatpak-json-oci.c b/common/flatpak-json-oci.c index aa89a03b4..58d0e58cf 100644 --- a/common/flatpak-json-oci.c +++ b/common/flatpak-json-oci.c @@ -595,7 +595,7 @@ flatpak_oci_index_get_manifest_for_arch (FlatpakOciIndex *self, for (i = 0; self->manifests[i] != NULL; i++) { - if (strcmp (self->manifests[i]->platform.architecture, oci_arch) == 0) + if (g_strcmp0 (self->manifests[i]->platform.architecture, oci_arch) == 0) return self->manifests[i]; }