From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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=-1.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no 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 C75A0C47404 for ; Thu, 12 Sep 2019 11:42:33 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id A6F2920693 for ; Thu, 12 Sep 2019 11:42:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731355AbfILLmc (ORCPT ); Thu, 12 Sep 2019 07:42:32 -0400 Received: from shards.monkeyblade.net ([23.128.96.9]:56534 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730982AbfILLmc (ORCPT ); Thu, 12 Sep 2019 07:42:32 -0400 Received: from localhost (unknown [148.69.85.38]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) (Authenticated sender: davem-davemloft) by shards.monkeyblade.net (Postfix) with ESMTPSA id BD0BC142D41F9; Thu, 12 Sep 2019 04:42:30 -0700 (PDT) Date: Thu, 12 Sep 2019 13:42:29 +0200 (CEST) Message-Id: <20190912.134229.2035407960151017293.davem@davemloft.net> To: torvalds@linux-foundation.org Cc: xiyou.wangcong@gmail.com, eric.dumazet@gmail.com, netdev@vger.kernel.org, syzbot+d5870a903591faaca4ae@syzkaller.appspotmail.com, jhs@mojatatu.com, jiri@resnulli.us Subject: Re: [Patch net] sch_sfb: fix a crash in sfb_destroy() From: David Miller In-Reply-To: References: <7b5b69a9-7ace-2d21-f187-7a81fb1dae5a@gmail.com> X-Mailer: Mew version 6.8 on Emacs 26.2 Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Thu, 12 Sep 2019 04:42:32 -0700 (PDT) Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: Linus Torvalds Date: Thu, 12 Sep 2019 11:31:06 +0100 > It depends on what you want to do, of course. Do you want to make sure > each user is being very careful? Or do you want to make the interfaces > easy to use without _having_ to be careful? There are arguments both > ways, but we've tended to move more towards a "easy to use" model than > the "be careful" one. Yes, I think allowing NULL or error pointers on free/destroy makes sense.