From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752832AbdCWHrm (ORCPT ); Thu, 23 Mar 2017 03:47:42 -0400 Received: from smtprelay0152.hostedemail.com ([216.40.44.152]:60407 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751363AbdCWHrk (ORCPT ); Thu, 23 Mar 2017 03:47:40 -0400 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::::::,RULES_HIT:41:355:379:541:599:973:988:989:1260:1277:1311:1313:1314:1345:1359:1373:1437:1515:1516:1518:1534:1540:1593:1594:1711:1730:1747:1777:1792:2110:2198:2199:2393:2559:2562:2828:3138:3139:3140:3141:3142:3352:3622:3865:3866:3867:3868:3871:3872:3874:4321:4605:5007:7653:8531:10004:10400:10848:11232:11658:11914:12043:12663:12740:12760:12895:13069:13161:13208:13229:13311:13357:13439:14659:14721:21063:21067:21080:21451:30022:30041:30054:30056:30070:30091,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:,MSBL:0,DNSBL:none,Custom_rules:0:0:0,LFtime:1,LUA_SUMMARY:none X-HE-Tag: town59_4cb6955757111 X-Filterd-Recvd-Size: 1808 Message-ID: <1490250520.2041.22.camel@perches.com> Subject: Re: [PATCH] checkpatch: Allow space leading blank lines in email headers From: Joe Perches To: Darren Hart Cc: Andrew Morton , Andy Whitcroft , "John 'Warthog9' Hawley" , linux-kernel@vger.kernel.org In-Reply-To: <20170323062057.GE17578@localhost.localdomain> References: <20170323062057.GE17578@localhost.localdomain> Content-Type: text/plain; charset="ISO-8859-1" Date: Wed, 22 Mar 2017 23:28:40 -0700 Mime-Version: 1.0 X-Mailer: Evolution 3.22.3-0ubuntu0.1 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2017-03-22 at 23:20 -0700, Darren Hart wrote: > I do have an open question regarding how we're going about testing for the end > of the header lines. Since we're not just testing for an empty line to separate > headers and body, there is clearly more going on here - but I'm not sure what it > is ... so I can't be sure this doesn't have an unintended consequence. > > > + $rawline =~ /^(?:commit\b|from\b|[\w-]+:)/i)) { > > This appears to be an unrelated change, introducing the non-capturing-group > (?:) and dropping the superfluous .*$ postfix. Did I get that right? Exactly right. The capturing of the initial bit of the match and testing of the rest of the line is simply unnecessary. I frequently make localized changes like that when I notice them. It's not a problem. cheers, Joe