From nobody Wed Nov 27 00:33:31 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=163.com ARC-Seal: i=1; a=rsa-sha256; t=1701856960; cv=none; d=zohomail.com; s=zohoarc; b=cMmqXrV0xIhavFmnbs02NB8NU+LMvXGn1DiWsB+Xn1GDDAXD4u4O+PhSsiO1Q1AwF2E2jGbiCKXdA6798QsGnBRNUjSp93Z7s81Kpb2NYa928i70qWATp4l0NY4GB+dmtaoVMpPQ8bv+yzVSElxK5IU0H5usfndPKrTbnbsqQRo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1701856960; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=lucAqjcAOxV7OyUhEMHxxl+sriz7SB5m4PKny50BcG4=; b=Ygl+wDJqQuDeKKoNDgQl8ggqgxwnESdDnxQsiXka4zCJ1laSO+PhccRIVhSo92aELYFmA/2r3Sfg0h9ilZ1zPvlXOj3TWEIuww2IFKw4RGdKe4RXRwvYk/jkM5XCmjjYBtfsIWvazZnAEJVTGm/2IZSL0LbG1DBkR/PlsPrJFU0= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1701856960509357.28070822763993; Wed, 6 Dec 2023 02:02:40 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rAoj4-0001tN-MT; Wed, 06 Dec 2023 05:01:54 -0500 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 1rAoj2-0001tA-Ll for qemu-devel@nongnu.org; Wed, 06 Dec 2023 05:01:53 -0500 Received: from m12.mail.163.com ([220.181.12.198]) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rAoiw-0001w0-Er for qemu-devel@nongnu.org; Wed, 06 Dec 2023 05:01:51 -0500 Received: from test123.sz.office (unknown [121.12.80.215]) by zwqz-smtp-mta-g5-2 (Coremail) with SMTP id _____wDntoRqRnBlsUI5Ew--.32175S2; Wed, 06 Dec 2023 18:01:29 +0800 (CST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com; s=s110527; h=From:Subject:Date:Message-Id:MIME-Version; bh=lucAq jcAOxV7OyUhEMHxxl+sriz7SB5m4PKny50BcG4=; b=nph7x0RixW6b0dAp82d4B WDOvmKpFDwVwY0zHu81DFnwIq187gDlSaj/hkkjSgaZRtBJD8oLZsZ3VVvKCCzcC loPDxAtWZmoXf8Gw1X1dPTKKqjkqLwtK1YYXBonc30mFQLGgAOrqaqPxVneSRo6F XRpyYAZcWLL07r4Cf+NhPA= From: lijiejun To: quintela@redhat.com, peterx@redhat.com, farosas@suse.de Cc: qemu-devel@nongnu.org, lijiejun Subject: [PATCH] migration: using qapi_free_SocketAddress instead of g_free Date: Wed, 6 Dec 2023 18:01:11 +0800 Message-Id: <20231206100111.2996016-1-a_lijiejun@163.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-CM-TRANSID: _____wDntoRqRnBlsUI5Ew--.32175S2 X-Coremail-Antispam: 1Uf129KBjvdXoWrZw4fZw45urW8AFyxJF47urg_yoW3KFg_u3 y09F4Y9as5GF43Ca1UWw18XrW3Ar4rJF95u343KrsxK34UAasxtr95A3s8X3yUJrsrKr15 Gw4qqFy3AasrGjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUvcSsGvfC2KfnxnUUI43ZEXa7xRtVyIJUUUUU== X-Originating-IP: [121.12.80.215] X-CM-SenderInfo: pdboxyplhm30i6rwjhhfrp/1tbiEBk+FF8YM7C1fAAAsu Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=220.181.12.198; envelope-from=a_lijiejun@163.com; helo=m12.mail.163.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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_BL=0.001, RCVD_IN_MSPIKE_L4=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham 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+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @163.com) X-ZM-MESSAGEID: 1701856961515100003 Content-Type: text/plain; charset="utf-8" use unified function qapi_free_SocketAddress to free SocketAddress object. Signed-off-by: lijiejun --- migration/migration.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/migration/migration.c b/migration/migration.c index 3ce04b2aaf..e78d31bbbf 100644 --- a/migration/migration.c +++ b/migration/migration.c @@ -493,7 +493,7 @@ bool migrate_uri_parse(const char *uri, MigrationChanne= l **channel, addr->u.socket.type =3D saddr->type; addr->u.socket.u =3D saddr->u; /* Don't free the objects inside; their ownership moved to "addr" = */ - g_free(saddr); + qapi_free_SocketAddress(saddr); } else if (strstart(uri, "file:", NULL)) { addr->transport =3D MIGRATION_ADDRESS_TYPE_FILE; addr->u.file.filename =3D g_strdup(uri + strlen("file:")); --=20 2.25.1