From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S946129AbcJSQRi (ORCPT ); Wed, 19 Oct 2016 12:17:38 -0400 Received: from mail-lf0-f68.google.com ([209.85.215.68]:33565 "EHLO mail-lf0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S938936AbcJSQRf (ORCPT ); Wed, 19 Oct 2016 12:17:35 -0400 Date: Wed, 19 Oct 2016 18:17:31 +0200 From: Michal Hocko To: Oleg Nesterov Cc: Leon Yu , Andrew Morton , Al Viro , Kees Cook , John Stultz , Mateusz Guzik , Janis Danisevskis , linux-kernel@vger.kernel.org Subject: Re: [PATCH] proc: fix NULL dereference when reading /proc//auxv Message-ID: <20161019161731.GK24393@dhcp22.suse.cz> References: <1476885580-7612-1-git-send-email-chianglungyu@gmail.com> <20161019141346.GJ7517@dhcp22.suse.cz> <20161019161207.GD21216@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20161019161207.GD21216@redhat.com> User-Agent: Mutt/1.6.0 (2016-04-01) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed 19-10-16 18:12:08, Oleg Nesterov wrote: > On 10/19, Michal Hocko wrote: > > > > Why would we even want to open that file if there is no mm struct? > > Agreed this is strange, but I am not sure we can change this old > behaviour. Say, cat /proc/$pid-of-kthread/mem doesn't fail, it shows > the "empty mm". What kind of application would break? Anything except for /proc/self/$file has to handle ESRCH already. -- Michal Hocko SUSE Labs