From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934798AbdAJPCG (ORCPT ); Tue, 10 Jan 2017 10:02:06 -0500 Received: from smtprelay0096.hostedemail.com ([216.40.44.96]:60479 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S934594AbdAJPCB (ORCPT ); Tue, 10 Jan 2017 10:02:01 -0500 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::::,RULES_HIT:41:355:379:541:599:800:960:973:982:988:989:1260:1277:1311:1313:1314:1345:1359:1373:1437:1515:1516:1518:1534:1538:1567:1593:1594:1711:1714:1730:1747:1777:1792:2393:2559:2562:2693:2828:3138:3139:3140:3141:3142:3622:3865:3868:3872:3873:3874:4321:5007:7576:7903:10004:10400:10450:10455:10848:11232:11658:11914:12296:12740:12760:12895:13069:13311:13357:13439:14181:14659:14721:19904:19999:21080:21451:30054:30064:30070:30091,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:none,Custom_rules:0:0:0,LFtime:2,LUA_SUMMARY:none X-HE-Tag: blade72_4b8d6858c3138 X-Filterd-Recvd-Size: 1277 Message-ID: <1484060517.2106.38.camel@perches.com> Subject: Re: [PATCH] checkpatch: don't warn on every struct without const_structs file From: Joe Perches To: Johannes Berg , Andrew Morton Cc: linux-kernel@vger.kernel.org, Johannes Berg Date: Tue, 10 Jan 2017 07:01:57 -0800 In-Reply-To: <20170110140318.737-1-johannes@sipsolutions.net> References: <20170110140318.737-1-johannes@sipsolutions.net> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.22.3-0ubuntu0.1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 2017-01-10 at 15:03 +0100, Johannes Berg wrote: > From: Johannes Berg > > The script says that it won't warn: > "No structs that should be const will be found [...]" > > but then that doesn't work and it warns on every single struct > instead, since the regular expression ends up empty. Fix that > by checking that it's not empty first. nak. How does const_structs end up empty for you?