From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752813AbbFLDyj (ORCPT ); Thu, 11 Jun 2015 23:54:39 -0400 Received: from smtprelay0235.hostedemail.com ([216.40.44.235]:46685 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751056AbbFLDyh (ORCPT ); Thu, 11 Jun 2015 23:54:37 -0400 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::,RULES_HIT:41:355:379:541:599:800:960:973:988:989:1260:1277:1311:1313:1314:1345:1359:1373:1437:1515:1516:1518:1534:1541:1593:1594:1711:1730:1747:1777:1792:2194:2199:2393:2553:2559:2562:2693:2828:2840:3138:3139:3140:3141:3142:3353:3622:3865:3866:3867:3868:3870:3871:3872:3874:4321:5007:6261:7903:9108:10004:10400:10848:10967:11232:11658:11914:12043:12438:12517:12519:12555:12740:13018:13019:13069:13160:13229:13311:13357:21080,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 X-HE-Tag: slip69_2814573960c4b X-Filterd-Recvd-Size: 2457 Message-ID: <1434081274.2972.26.camel@perches.com> Subject: Re: diffs in changelogs From: Joe Perches To: Andrew Morton Cc: linux-kernel@vger.kernel.org, Kent Overstreet Date: Thu, 11 Jun 2015 20:54:34 -0700 In-Reply-To: <20150611202135.ee070955.akpm@linux-foundation.org> References: <20150611134006.9df79a893e3636019ad2759e@linux-foundation.org> <1434078779.2972.23.camel@perches.com> <20150611202135.ee070955.akpm@linux-foundation.org> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.12.11-0ubuntu3 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 Thu, 2015-06-11 at 20:21 -0700, Andrew Morton wrote: > On Thu, 11 Jun 2015 20:12:59 -0700 Joe Perches wrote: > > > On Thu, 2015-06-11 at 13:40 -0700, Andrew Morton wrote: > > > People often put diff snippets in changelogs. This causes problems > > > when one tries to apply a file containing both the changelog and the > > > diff because patch(1) tries to apply the diff which it found in the > > > changelog. > > That > > > eg, something like > > > > > > git show d24a6e1087030b6da | patch -p1 > > > > > > will go haywire. > > > > > > So can we please have a checkpatch test warning people away from doing > > > this? > > > > > > > > > patch(1) seems to be really promiscuous in its detection of a patch. I > > > haven't had much success searching for "^--- " and similar. What works > > > best for me is searching for "^[whitespace]@@ -". > > > > I don't think that's a good test. > > Coccinelle uses @@ > > > > And how did that commit actually get applied? > > Good question. Maybe `git apply' is smarter about this than patch(1)? Dunno. git am failed. My guess is it was applied normally and then git commit --amend added the other diff content > > I tried applying it to a new branch checked out at > > ce2b3f595e1c56639085645e0130426e443008c0, it fails. > > There are tons of them: > > z:/usr/src/git26> git log | grep "^[ ]*@@ -" | wc -l > 120 > > > Anyway, maybe: > > Looks good, thanks. -ENOCHANGELOG. Please send it for real when convenient. RFCPATCH