From patchwork Mon Sep 25 14:48:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 726031 Delivered-To: patch@linaro.org Received: by 2002:adf:ea87:0:b0:31d:da82:a3b4 with SMTP id s7csp2434165wrm; Mon, 25 Sep 2023 07:56:19 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGqGcZ95rYvHuo/Sc2PgeRcHCx7vua1JmKjMIWx6EUYxg3eH7QRnlDpfBFLkFqs8GKVMsrj X-Received: by 2002:a05:622a:248:b0:40b:2370:3d32 with SMTP id c8-20020a05622a024800b0040b23703d32mr7705814qtx.0.1695653778848; Mon, 25 Sep 2023 07:56:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695653778; cv=none; d=google.com; s=arc-20160816; b=0WL3vNVa19PLxhl9d3J2UznFU421E/FQ6MR2SJGl1b6zhJuNTTXdXbiXYtDMB+Gap7 IS7E11VJsO7rIdlSAiyFvXI5si126Xq7deVy/yse/gwRbD7Xp+bJXCtCu4ZoZkEVNWFI uidCORHdPPCE3ChRkII3uZwqWavbpASR1C8Iyk1+v2Kxhiq2QfEgHXDIyBNo4MK4gZbn ZB0ignx9bFE+vLgibfdlZH3YlrP78WB2YuXKMQ2U2W6ALYs7oZJVMx+ypt5Xa7IaWe8P 4DprlGfuKXfd2e8EdhjhqP+iyV7WBV2Oys/+UKpxHvRhtc7BF21YOTtpPrGWcMVWXGzC 0azQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=kNHX4JyhoYexAQqB9a7CrjUa8yJRKrNW0ix3Ut30RxE=; fh=mlkRjkvEMCBvV2NmkuZ9E+MTYOKspqfxSPvD1d2xG14=; b=TIKqzGIaK4L0ymsZ49fnnBJn/Ly67MiSlBM1IGUQ1lCyQd0cNcfdnjYV/pMthFPJ8C 24R96qbT6z0XVYbXzTudg+be9LZgOppNQYF03s3s7sxQw7OXGe3dNQnuQGzvyPU67Zm9 nGiGa0PJCOOo26h96hbiYg3hR9oCL38TmcmlRFXKXz9POLm/I4rVXa6wwQ8hbL7kTbhw omdxrzm1WFNAs6Y9WtfrbqX/BbKHV/f3PGz7yqElXb2m8QztHkZoKWlPghole2RP97bW fXEGQEuz/PIiodZrATOGICrr+GyBCGNF269JRHqVEEV8x/+eLDYDFMFMCSu0A+eMG93Y dqbQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=o7okgtlz; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id z13-20020a05622a060d00b00403be2ad0besi6209673qta.11.2023.09.25.07.56.18 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 25 Sep 2023 07:56:18 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=o7okgtlz; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qkmtl-0001T0-VP; Mon, 25 Sep 2023 10:49:22 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qkmtc-00014e-Rq for qemu-devel@nongnu.org; Mon, 25 Sep 2023 10:49:13 -0400 Received: from mail-wm1-x332.google.com ([2a00:1450:4864:20::332]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qkmtQ-0008Gx-Jv for qemu-devel@nongnu.org; Mon, 25 Sep 2023 10:49:12 -0400 Received: by mail-wm1-x332.google.com with SMTP id 5b1f17b1804b1-40572aeb73cso31127225e9.3 for ; Mon, 25 Sep 2023 07:49:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1695653339; x=1696258139; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=kNHX4JyhoYexAQqB9a7CrjUa8yJRKrNW0ix3Ut30RxE=; b=o7okgtlzKM5CdQPEsjYaWC/JCovzE4x9nZPmryzKjLnYr+KwgIO92EBcllUVMpLwTP yKnPWH0bXZxePEqYhd9oIhyDONqAjFYEgSnEJNIJhHMylwUhDWNuq3wz1a2gA94Iosqf zK0NGvhXonwTmUQK0iqkt/yuQEJTiZIoQ9p9ztLGBJ1OVvJUafe7O3L7URsoNUgdVG+C MMOU4aLBkD+pAeVmDmTBsSyJBgcU4yec65/QoVZocVYpOuE5mqAyrd1u7z0Jv6SZ6p8V +P+0H5hUHuzDfNJsvFofxv7sqxvAnfW6lj5K4zpte5ZzbFr1SY7KpIkZZqIma2JZM23t Ch8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695653339; x=1696258139; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=kNHX4JyhoYexAQqB9a7CrjUa8yJRKrNW0ix3Ut30RxE=; b=i3Iq+lp9GJ8oE0MSbqlUSRqTDTp08n6A8mc59XesgBa1cLHziCElRYD6lL4toDPRHj kVlbPgamlLLR9nZOrb8mHf3cHcFbptn3zNR7UnVo0F61p2+w4oDX1ks9oLXezkMCVdkR MHTSWlJCM6gYTv+wSWBF1BA0ol1DLuGtJdopuSnLHZ/aoW1E1CA2vXgQLMTfflvDD7RV 6tDh2z7EXn1WI29ZdXDJtAVV7JUM2rWhcdqc4vcZ/4MyuZV9Qu9pEbTfsb5wqnmGGGjP 4ZN7yQIyGw+2WItDJQd1RsrIdToDIIGUxa2GYV60yfQoJR5PFhN75ZbkGTmFAFejlByM AzhA== X-Gm-Message-State: AOJu0YzpDjv7y9aq65nYI/JhVLHQ/DkryDT59B7fD4d4ZEs75IfYuHSa q5V/Rm4pBMozd9lOyH8TDr+oSw== X-Received: by 2002:a05:600c:5192:b0:405:75f0:fd31 with SMTP id fa18-20020a05600c519200b0040575f0fd31mr3794870wmb.31.1695653339092; Mon, 25 Sep 2023 07:48:59 -0700 (PDT) Received: from zen.linaroharston ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id 8-20020a05600c230800b003fe61c33df5sm15386125wmo.3.2023.09.25.07.48.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 25 Sep 2023 07:48:57 -0700 (PDT) Received: from zen.linaroharston (localhost [127.0.0.1]) by zen.linaroharston (Postfix) with ESMTP id 1A8A31FFBB; Mon, 25 Sep 2023 15:48:56 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: Alistair Francis , =?utf-8?q?C=C3=A9dric_Le_Go?= =?utf-8?q?ater?= , Marcin Juszkiewicz , John Snow , libvir-list@redhat.com, =?utf-8?q?Marc-Andr?= =?utf-8?q?=C3=A9_Lureau?= , qemu-s390x@nongnu.org, Song Gao , Daniel Henrique Barboza , Marcel Apfelbaum , Bastian Koppelmann , Liu Zhiwei , Weiwei Li , Nicholas Piggin , Radoslaw Biernacki , =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= , Eduardo Habkost , Cleber Rosa , Paolo Bonzini , Mahmoud Mandour , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , Thomas Huth , Wainer dos Santos Moschetta , Richard Henderson , Bin Meng , Alexandre Iooss , Xiaojuan Yang , qemu-ppc@nongnu.org, David Hildenbrand , =?utf-8?q?Alex_Benn=C3=A9e?= , Yanan Wang , Peter Maydell , qemu-riscv@nongnu.org, qemu-arm@nongnu.org, Palmer Dabbelt , Ilya Leoshkevich , Laurent Vivier , Yoshinori Sato , Leif Lindholm , Beraldo Leal , Akihiko Odaki Subject: [PATCH 09/31] gdbstub: Fix target_xml initialization Date: Mon, 25 Sep 2023 15:48:32 +0100 Message-Id: <20230925144854.1872513-10-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20230925144854.1872513-1-alex.bennee@linaro.org> References: <20230925144854.1872513-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::332; envelope-from=alex.bennee@linaro.org; helo=mail-wm1-x332.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org From: Akihiko Odaki target_xml is no longer a fixed-length array but a pointer to a variable-length memory. Fixes: 56e534bd11 ("gdbstub: refactor get_feature_xml") Signed-off-by: Akihiko Odaki Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20230912224107.29669-2-akihiko.odaki@daynix.com> Signed-off-by: Alex Bennée --- gdbstub/softmmu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gdbstub/softmmu.c b/gdbstub/softmmu.c index 9f0b8b5497..42645d2220 100644 --- a/gdbstub/softmmu.c +++ b/gdbstub/softmmu.c @@ -292,7 +292,7 @@ static int find_cpu_clusters(Object *child, void *opaque) assert(cluster->cluster_id != UINT32_MAX); process->pid = cluster->cluster_id + 1; process->attached = false; - process->target_xml[0] = '\0'; + process->target_xml = NULL; return 0; }