From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753758AbdKXUh4 (ORCPT ); Fri, 24 Nov 2017 15:37:56 -0500 Received: from mail-pl0-f65.google.com ([209.85.160.65]:46154 "EHLO mail-pl0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753584AbdKXUhy (ORCPT ); Fri, 24 Nov 2017 15:37:54 -0500 X-Google-Smtp-Source: AGs4zMYikoBU6wPr3YvRcDv0ZLRAhyHPw7QTQZKbQBrC1iKrFIkG0pJYm7ZMokbZASI5JI9U5ri/dw== Date: Fri, 24 Nov 2017 12:37:50 -0800 From: Eric Biggers To: David Howells Cc: keyrings@vger.kernel.org, linux-security-module@vger.kernel.org, linux-kernel@vger.kernel.org, Eric Biggers Subject: Re: [PATCH] KEYS: remove unnecessary get/put of explicit dest_keyring Message-ID: <20171124203750.GA559@zzz.localdomain> References: <20171120225757.96498-1-ebiggers3@gmail.com> <23022.1511538725@warthog.procyon.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <23022.1511538725@warthog.procyon.org.uk> User-Agent: Mutt/1.9.1 (2017-09-22) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 24, 2017 at 03:52:05PM +0000, David Howells wrote: > Eric Biggers wrote: > > > - construct_get_dest_keyring(&dest_keyring); > > This will break. construct_get_dest_keyring() does other things than just > getting a ref on whatever dest_keyring points to. > Not if dest_keyring is non-NULL (i.e. explicitly specified), which it is in this case. Eric