Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp416704imm; Thu, 26 Jul 2018 22:38:43 -0700 (PDT) X-Google-Smtp-Source: AAOMgpcRy4Wkyk4bamOgH1bQwYlZFT3+2E9isLn0MLD+JpCnfxgravmU/cVrs9ssfNrhSGXu3KFR X-Received: by 2002:a65:6109:: with SMTP id z9-v6mr4658957pgu.243.1532669923200; Thu, 26 Jul 2018 22:38:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532669923; cv=none; d=google.com; s=arc-20160816; b=r/nX+j4yWCVhDYnzqDe8uJSAc/ijuBnNPK865A6pIj7AvZkzZJQDqq7EF5j9a1d2Wl eTa+8qzgS0mxBNIOJ7oVOfoFgFGb19+g2lGi4pd9QPUgUyMUDwAiqjBJ3HbHIW2SCpjP jvoIcP5fHXFXQ3yJ4qnHm4tXh63jBABWR6E4w37qMdhwG2OhtC1IVskvwdjft7mKvqHO 7q2g2iZt3N6Uc6Z8scUB1fgFXfGdeTHgcn2ZFOfd0c0WP6SkJSe3duv9p8DphIzQTy2R Lmf2awNEzdI8txHTqmqsqF0ma6FKnp5CrHzLqpMF2mKLjl7/W4lHFZ7sPMGkhhAfN56M PHDQ== 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:message-id:subject:cc :to:from:date:arc-authentication-results; bh=bxQTE2rMZ1szMoapjnGBHNH1VXQyPljYQFg34fd3jBM=; b=FNrFHJ2b86JwxbS+Zg2N/6ywxZrS6qdDzQTJWatGTK+wtHIPKdWfn6OpPlWnZ4b4vI OYdvS391OfsMHpnY+Olylx45RxMLf4KP6rOL0cBiDoY+8xS7V3KUidG6+4bL1mCUHnij eiCEBOhKE+TvBvv7v23wpBZGxu/rZihG311cptk2nLfTZpQeEG7qx5SrMXxBdHrc0M16 M86ERKibZHP8vLpS97KOeKBTlIIjtfCyYNTyT4pq9LY0uLW47npaqFv+Exj4CAf7O6ZO n++0icE4PwWNurIRtlS8L72HhigO2myeJlkh3pRvCpGG8GwwrwAdM9MIc97LPEKjuwh0 sS1w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 23-v6si3064782pgx.323.2018.07.26.22.38.25; Thu, 26 Jul 2018 22:38:43 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729498AbeG0G5k (ORCPT + 99 others); Fri, 27 Jul 2018 02:57:40 -0400 Received: from a.mx.secunet.com ([62.96.220.36]:54124 "EHLO a.mx.secunet.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725861AbeG0G5j (ORCPT ); Fri, 27 Jul 2018 02:57:39 -0400 Received: from localhost (localhost [127.0.0.1]) by a.mx.secunet.com (Postfix) with ESMTP id 45D2B20092; Fri, 27 Jul 2018 09:37:13 +0200 (CEST) X-Virus-Scanned: by secunet Received: from a.mx.secunet.com ([127.0.0.1]) by localhost (a.mx.secunet.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id QvBr2Ha50ySn; Fri, 27 Jul 2018 09:37:12 +0200 (CEST) Received: from mail-essen-01.secunet.de (mail-essen-01.secunet.de [10.53.40.204]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by a.mx.secunet.com (Postfix) with ESMTPS id 35E5B20087; Fri, 27 Jul 2018 09:37:12 +0200 (CEST) Received: from gauss2.secunet.de (10.182.7.193) by mail-essen-01.secunet.de (10.53.40.204) with Microsoft SMTP Server id 14.3.399.0; Fri, 27 Jul 2018 07:37:27 +0200 Received: by gauss2.secunet.de (Postfix, from userid 1000) id D1E5C318201B; Fri, 27 Jul 2018 07:37:26 +0200 (CEST) Date: Fri, 27 Jul 2018 07:37:26 +0200 From: Steffen Klassert To: YueHaibing CC: , , , Subject: Re: [PATCH ipsec-next] xfrm: fix 'passing zero to ERR_PTR()' warning Message-ID: <20180727053726.hxw5hrbbq3e2xw6o@gauss3.secunet.de> References: <20180725085433.18756-1-yuehaibing@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: <20180725085433.18756-1-yuehaibing@huawei.com> User-Agent: NeoMutt/20170609 (1.8.3) X-G-Data-MailSecurity-for-Exchange-State: 0 X-G-Data-MailSecurity-for-Exchange-Error: 0 X-G-Data-MailSecurity-for-Exchange-Sender: 23 X-G-Data-MailSecurity-for-Exchange-Server: d65e63f7-5c15-413f-8f63-c0d707471c93 X-EXCLAIMER-MD-CONFIG: 2c86f778-e09b-4440-8b15-867914633a10 X-G-Data-MailSecurity-for-Exchange-Guid: 4B1D697D-ED6C-4F45-BCC0-221BDC8504D7 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jul 25, 2018 at 04:54:33PM +0800, YueHaibing wrote: > Fix a static code checker warning: > > net/xfrm/xfrm_policy.c:1836 xfrm_resolve_and_create_bundle() warn: passing zero to 'ERR_PTR' > > xfrm_tmpl_resolve return 0 just means no xdst found, return NULL > instead of passing zero to ERR_PTR. > > Fixes: d809ec895505 ("xfrm: do not assume that template resolving always returns xfrms") > Signed-off-by: YueHaibing Applied, thanks a lot!