Message ID | 20210309144015.557477-2-david.edmondson@oracle.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <SRS0=D4wg=IH=nongnu.org=qemu-devel-bounces+qemu-devel=archiver.kernel.org@kernel.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,MSGID_FROM_MTA_HEADER,SPF_HELO_NONE,SPF_PASS, UNPARSEABLE_RELAY,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C16A3C433DB for <qemu-devel@archiver.kernel.org>; Tue, 9 Mar 2021 15:17:20 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 73675651AE for <qemu-devel@archiver.kernel.org>; Tue, 9 Mar 2021 15:17:19 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 73675651AE Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=oracle.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Received: from localhost ([::1]:32920 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from <qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org>) id 1lJe6o-0002Mv-CQ for qemu-devel@archiver.kernel.org; Tue, 09 Mar 2021 10:17:18 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:46556) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <david.edmondson@oracle.com>) id 1lJdXI-0002ok-C4; Tue, 09 Mar 2021 09:40:40 -0500 Received: from userp2130.oracle.com ([156.151.31.86]:37304) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from <david.edmondson@oracle.com>) id 1lJdXB-0003nO-M0; Tue, 09 Mar 2021 09:40:36 -0500 Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 129Edwd5153306; Tue, 9 Mar 2021 14:40:25 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : content-type : content-transfer-encoding : mime-version; s=corp-2020-01-29; bh=6X00bJZSU8oM4dFY4zWwMUXZMkp/GRsK7l1Po9JrRgA=; b=i9qHtUkUgQJ5KEkbzkwGufQGPcq25rpFdBf2y7YtAU16aYcrdeuWOZlNW1/j7zfMkuku HthN3KiyxwdUSuwBR19RC2dVIg2T6ZsYFuHuCJtdTj3vyeH2lTVZJ5WKbcDqG7Z8vJO/ yzhDV+zR2wvGQ7/KtrdhAB/GoFre4tdCD8+hxCxmLBriQzeDRtJ0vauJpj5z7ogo6929 PZJJple7KbK1Azkaa+I+dMy/0HWaay3mABk+W/PxrSuEYjx+TQLHei+XxZxvnI3ebObT 41xY6oxWbooxMdCXhrpEnLwDkswMP+EKA9Oljmc9AYZz7e0xX070nbE7JkC8Gy9Ez43p mA== Received: from userp3030.oracle.com (userp3030.oracle.com [156.151.31.80]) by userp2130.oracle.com with ESMTP id 37415r7gh6-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 09 Mar 2021 14:40:25 +0000 Received: from pps.filterd (userp3030.oracle.com [127.0.0.1]) by userp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 129EVOYn193150; Tue, 9 Mar 2021 14:40:24 GMT Received: from nam12-mw2-obe.outbound.protection.outlook.com (mail-mw2nam12lp2046.outbound.protection.outlook.com [104.47.66.46]) by userp3030.oracle.com with ESMTP id 374knwwjvh-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 09 Mar 2021 14:40:24 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=nYfSuX7p5GiGsoFwkGPgc3XLzKc3S8TLQvdp4WeI1YQhtIPvMjuOjLSsNW9cD8kbkArzptsy2u/8yy7p+3RvV1NK0ziMlZmLmierEsRFYId5PzSp81+0wYhOXnfxDcR4BXEUKiWQNA94WZiKL2b1nfvMLi7cu5V3iV68SjLops3l5LHfgHGMr9i83SddAa5a2hUs532KB3odHwlbxhBh3d3Bfs3wOchlVilJk72tIM4whRCI66lmI6v+8+znph/UnSrl5ox0fq2sVqw7PVliv89U3P8LUDUJwJq0EVpQLUj8sH7MLRMKtxK7iOqxo5SYvUQd2dBolvlDUgk7MVm04g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=6X00bJZSU8oM4dFY4zWwMUXZMkp/GRsK7l1Po9JrRgA=; b=GQWtQ59tUqRx8AALPmSHAVFenQsTQ5gCf2+qvbt2UvdlbQqGo4ytUPDNbL/lU4gZSVNJyPVHbMzpepF2vZxnsmpGaofjvANPog6BC9XJdDv5w2C6g47hDqP9QwBQT4Mxowbmn9DndkyiYQy97hchydKJFhje8DPltlvqfLwUpFoAgxZf9UArcvg3meMX6hJ0N5uVZVeSVFi8iQVUGi6/b7hmOBrjpmUr/NgcTfUpViACAz3Qju66kgfY3BgaAgI2ePGRm1asxuMc4XitqSGqZ/vc8PFnuCB+Q29iBdmAdFk9f2YkcPI2HqiALEU0PH1ECvarDsL7VKc9JmWyCEHPFw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=6X00bJZSU8oM4dFY4zWwMUXZMkp/GRsK7l1Po9JrRgA=; b=OfOvzPK/+bPm0Vl0XRCslvPpJFXaD+x1Y1m1v1y4AtKXP6M1Kemwg+uStGEBGyQAS4mR/3qZDFPIcPczRiC+PCneyUr9JNx4gCwdUbXZBkQ/t+4Wwi45nv4rD/2M7Voj5dhhzpgJ73mYJ945JL3EwiWDYuAu8nzlZoaIMFU08oM= Authentication-Results: redhat.com; dkim=none (message not signed) header.d=none;redhat.com; dmarc=none action=none header.from=oracle.com; Received: from DM6PR10MB3148.namprd10.prod.outlook.com (2603:10b6:5:1a4::21) by DM5PR10MB1771.namprd10.prod.outlook.com (2603:10b6:4:8::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3912.29; Tue, 9 Mar 2021 14:40:22 +0000 Received: from DM6PR10MB3148.namprd10.prod.outlook.com ([fe80::f871:5965:2081:3934]) by DM6PR10MB3148.namprd10.prod.outlook.com ([fe80::f871:5965:2081:3934%5]) with mapi id 15.20.3890.038; Tue, 9 Mar 2021 14:40:22 +0000 From: David Edmondson <david.edmondson@oracle.com> To: qemu-devel@nongnu.org Subject: [PATCH v2 1/6] block/vdi: When writing new bmap entry fails, don't leak the buffer Date: Tue, 9 Mar 2021 14:40:10 +0000 Message-Id: <20210309144015.557477-2-david.edmondson@oracle.com> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210309144015.557477-1-david.edmondson@oracle.com> References: <20210309144015.557477-1-david.edmondson@oracle.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Originating-IP: [2001:8b0:bb71:7140:64::1] X-ClientProxiedBy: LO2P265CA0214.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:9e::34) To DM6PR10MB3148.namprd10.prod.outlook.com (2603:10b6:5:1a4::21) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from disaster-area.hh.sledj.net (2001:8b0:bb71:7140:64::1) by LO2P265CA0214.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:9e::34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3912.26 via Frontend Transport; Tue, 9 Mar 2021 14:40:21 +0000 Received: from localhost (disaster-area.hh.sledj.net [local]) by disaster-area.hh.sledj.net (OpenSMTPD) with ESMTPA id 4b3c2d4d; Tue, 9 Mar 2021 14:40:15 +0000 (UTC) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 18c55d63-0723-4e30-a91e-08d8e3094505 X-MS-TrafficTypeDiagnostic: DM5PR10MB1771: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: <DM5PR10MB177142BEE5A105AEA74249A188929@DM5PR10MB1771.namprd10.prod.outlook.com> X-MS-Oob-TLC-OOBClassifiers: OLM:3968; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 4s5oCH6ZnLIGgLo2jnr8Ru+YrJhsX+esCAEJeX+qnOTps09E68h5gvB9G8AwuzRO58I04uhPsu6SjKM3fnSMU2jdx+PLtNKcJmURBkUeX8dSIA1OoDLJVB4xUXF9iJOma2joLyFB4K5odwgdLIHPpgtYHgIFQm8ZgaAcqzHo1eyXkTxe1Ns9pCaqnTOkkUsmB+RlT+ZcaVIuGpREKjXPdmCCiQR1oq0HbXqCgAiY+qHrVb6UtgnHLAXJlnFRFA9I3WQ2J/7LjRMYbhiriY4PPVpkGAoKg4PyIHeOyn3zbHhO5ArGkqWKaLYZKJFjH76ihFMczwVxzbInFZ2qUqIhJqw/JXjqq/RT9/rS+VP2ee7hmMUmg3QlWzFHoH1H1Hliburj0jSXYgeAWj6Al1Cuuc06Q9g59WQRpBz+3a++RpyFYiB/B9Dc63YJtptWMp7c1Z2CFl14SHNF1ZTJkjW+WiXN5dlLamI1JehxZ2Cbfh0omtpoqRVFvznveFb2Gr/bH1dDUAP2cSvnQyinmrRH8Q== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DM6PR10MB3148.namprd10.prod.outlook.com; PTR:; CAT:NONE; SFS:(366004)(39860400002)(346002)(396003)(376002)(136003)(86362001)(186003)(83380400001)(66946007)(44832011)(316002)(52116002)(1076003)(36756003)(8676002)(8936002)(54906003)(66556008)(6916009)(478600001)(2616005)(4744005)(5660300002)(4326008)(2906002)(6666004)(66476007); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData: =?utf-8?q?+/lWq7nLwT/pJfxbkyJUv+EAh2lDfS?= =?utf-8?q?VY6Xd+raRHMvsK7dVyIswu2NzrXi0l6/wbpcadbKbj4E5sEliKBQEOj9j8UUwswlO?= =?utf-8?q?ljcMJ9ZibYmD2JJV4TzSFba5vaKr/fnz4bTsZeVif7KiRAqP3MDH6pVK2jzOKVM/Q?= =?utf-8?q?Fvk1qIYImES6WVhqObgTll1k2HKLH/Qk7HisiWlsSMCK/wJWaq7MTxcCPWmOw2rtr?= =?utf-8?q?h5fTGwSJjRdn3nnRKqFg5Ds8Y8o6h/KAu7Sp32AXnSsaUv4+DdIF9biCIEtCLUlff?= =?utf-8?q?Xwt3n1GhvbiIuIYUh99jwm/hvXT9VK/XOJAoITNnVOAEKmlcwahJXWeyCeibHnhL1?= =?utf-8?q?m9SZLXvCA6/+QuyC2b4vh8YHgeIS9LQmgxyGC+o3KsPtabUseaAGHM9e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QHs7YFk1YEOoDRijHJ1MB?= =?utf-8?q?uXWMtixXpZELcGjYZZO9sZdc9j41AuOOST3Q=3D=3D?= X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: 18c55d63-0723-4e30-a91e-08d8e3094505 X-MS-Exchange-CrossTenant-AuthSource: DM6PR10MB3148.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Mar 2021 14:40:22.7643 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: URhhzJvYNwgQNSlxZSnFWHRxQ9KvCd7aq5EMPZAmfD8I5brupoBdX78wa9D7s1keTB2NCBSlDF1eKe6mlvLusxqaGuGc/WVgBSastqrYono= X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR10MB1771 X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=9917 signatures=668683 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 suspectscore=0 adultscore=0 phishscore=0 malwarescore=0 mlxscore=0 bulkscore=0 mlxlogscore=999 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2103090074 X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=9917 signatures=668683 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxscore=0 lowpriorityscore=0 impostorscore=0 mlxlogscore=999 malwarescore=0 suspectscore=0 adultscore=0 phishscore=0 spamscore=0 priorityscore=1501 bulkscore=0 clxscore=1015 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2103090075 Received-SPF: pass client-ip=156.151.31.86; envelope-from=david.edmondson@oracle.com; helo=userp2130.oracle.com X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 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, MSGID_FROM_MTA_HEADER=0.001, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, UNPARSEABLE_RELAY=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: <qemu-devel.nongnu.org> List-Unsubscribe: <https://lists.nongnu.org/mailman/options/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=unsubscribe> List-Archive: <https://lists.nongnu.org/archive/html/qemu-devel> List-Post: <mailto:qemu-devel@nongnu.org> List-Help: <mailto:qemu-devel-request@nongnu.org?subject=help> List-Subscribe: <https://lists.nongnu.org/mailman/listinfo/qemu-devel>, <mailto:qemu-devel-request@nongnu.org?subject=subscribe> Cc: Kevin Wolf <kwolf@redhat.com>, qemu-block@nongnu.org, Stefan Weil <sw@weilnetz.de>, Max Reitz <mreitz@redhat.com>, David Edmondson <david.edmondson@oracle.com>, Stefan Hajnoczi <stefanha@redhat.com>, =?utf-8?q?Philippe_Mathieu-Daud?= =?utf-8?q?=C3=A9?= <philmd@redhat.com> Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" <qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org> |
Series |
coroutine rwlock downgrade fix, minor VDI changes
|
expand
|
diff --git a/block/vdi.c b/block/vdi.c index 5627e7d764..2a6dc26124 100644 --- a/block/vdi.c +++ b/block/vdi.c @@ -690,6 +690,7 @@ nonallocating_write: logout("finished data write\n"); if (ret < 0) { + g_free(block); return ret; }