Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp3006999ybz; Mon, 27 Apr 2020 08:22:52 -0700 (PDT) X-Google-Smtp-Source: APiQypLwWspc0zSMG/tK1SHSHY1aMMKC+lbdEEbfXnaE7xxQMm2r6nMY/meyy6p4EKw2YxUzsu9s X-Received: by 2002:a17:907:9481:: with SMTP id dm1mr20828129ejc.9.1588000972443; Mon, 27 Apr 2020 08:22:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588000972; cv=none; d=google.com; s=arc-20160816; b=JtAmiPqKfy1nq6MNsmGyHxpslQBaZwbK93hsm8dlznBi7nEBgHYr/gAU5G0FtIZZoM NbwYIHAUEH+EzWiiqI7SuddQMyVZu1AMsjxeNUiBZ65jPdOTfVV+GAP4g5vmjN6VGHjt TYYdKNDtd/G8PRiQDh4rvcYuOD6dev8y8mqeFUBtYDmLmesAkBUCTq326OF7x9Kx3svS DhQdxieZNtCp3jV/s98c1bjZjMqqJIXLUSmk2e20//xnbF7I1Dkl+Do2LNgOwuvokwCx KYl5ETj8qx8qpriB7SarOSpRkXw7bqmuZeoE6faeM3cJjjZtMo1FV/Wf2nOZICdNiwMe KVTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:mail-followup-to :reply-to:message-id:subject:cc:to:from:date; bh=m0WRgwXjFUNu+u7jK32Xdu79TGuxJO8w3jTfIY6woMQ=; b=j6XiNFlnHTINnioL4MPD0SDzQp/nlPcxkaASVsoqc4N6Hr8xHyr7OsRxaM9TxfQLM0 Oub8q98PhUKwXPLW/095PcjX3r7EeCYwEi4UkK6vkLztZEGrwYOonlxJjEQW3/q4e/fh oa+XCm5vj6IRRGIUEh5jKbdFAtiY0EEdJTS6DTCUJCRACzJs9w40SHkcOzbbDCMxH7Uz sd4Wb8jAuv6cWMrJqRjwITlWA0CgLNpeaSp8YcCrLJz7Dm9fSDabjyCZkXBVm+q72QMw U/+bkvlIYG9YBKpqz3VaH6gO+9fYKgfd+IEQs6dOWv/SxOhuq8OCXDNxt2FfrqLEL9qN 8dQw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w20si8233672ejq.91.2020.04.27.08.22.29; Mon, 27 Apr 2020 08:22:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728175AbgD0PSx (ORCPT + 99 others); Mon, 27 Apr 2020 11:18:53 -0400 Received: from mx2.suse.de ([195.135.220.15]:48016 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726539AbgD0PSw (ORCPT ); Mon, 27 Apr 2020 11:18:52 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 573B3AEBF; Mon, 27 Apr 2020 15:18:50 +0000 (UTC) Received: by ds.suse.cz (Postfix, from userid 10065) id CB77EDA781; Mon, 27 Apr 2020 17:18:05 +0200 (CEST) Date: Mon, 27 Apr 2020 17:18:05 +0200 From: David Sterba To: Colin King Cc: Chris Mason , Josef Bacik , David Sterba , Johannes Thumshirn , Qu Wenruo , linux-btrfs@vger.kernel.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH][next] btrfs: fix check for memory allocation failure of ret->path Message-ID: <20200427151805.GC18421@twin.jikos.cz> Reply-To: dsterba@suse.cz Mail-Followup-To: dsterba@suse.cz, Colin King , Chris Mason , Josef Bacik , David Sterba , Johannes Thumshirn , Qu Wenruo , linux-btrfs@vger.kernel.org, kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org References: <20200421124703.149466-1-colin.king@canonical.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200421124703.149466-1-colin.king@canonical.com> User-Agent: Mutt/1.5.23.1-rc1 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Apr 21, 2020 at 01:47:03PM +0100, Colin King wrote: > From: Colin Ian King > > Currently the memory allocation failure check for ret->path is checking > that ret is null rather than ret->path. Fix this by checking ret->path > instead. > > Addresses-Coverity: ("Dereference null return") > Fixes: bd8bdc532152 ("btrfs: backref: introduce the skeleton of btrfs_backref_iter") As this is still in development branch, fixup folded in. Thanks.