From patchwork Tue Feb 21 09:06:40 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sven Eckelmann X-Patchwork-Id: 16957 X-Patchwork-Delegate: sw@simonwunderlich.de Return-Path: X-Original-To: patchwork@open-mesh.org Delivered-To: patchwork@open-mesh.org Received: from open-mesh.org (localhost [IPv6:::1]) by open-mesh.org (Postfix) with ESMTP id 0760182E2C; Tue, 21 Feb 2017 10:06:56 +0100 (CET) Authentication-Results: open-mesh.org; dmarc=none header.from=narfation.org Authentication-Results: open-mesh.org; dkim=fail reason="verification failed; unprotected key" header.d=narfation.org header.i=@narfation.org header.b=kJ5EYDlK; dkim-adsp=fail (unprotected policy); dkim-atps=neutral Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2001:4d88:2000:7::2; helo=v3-1039.vlinux.de; envelope-from=sven@narfation.org; receiver=b.a.t.m.a.n@lists.open-mesh.org Authentication-Results: open-mesh.org; dmarc=pass header.from=narfation.org Received: from v3-1039.vlinux.de (narfation.org [IPv6:2001:4d88:2000:7::2]) by open-mesh.org (Postfix) with ESMTPS id 8C0538134F for ; Tue, 21 Feb 2017 10:06:53 +0100 (CET) Received: from sven-desktop.home.narfation.org (p4FFE49A8.dip0.t-ipconnect.de [79.254.73.168]) by v3-1039.vlinux.de (Postfix) with ESMTPSA id D9E251100CD for ; Tue, 21 Feb 2017 10:06:52 +0100 (CET) Authentication-Results: v3-1039.vlinux.de; dmarc=none header.from=narfation.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=narfation.org; s=20121; t=1487668013; bh=DnBCa2QHoF4TZ+v6+ZQtXZMIOPExgHFgdXII2G9dQHs=; h=From:To:Subject:Date:From; b=kJ5EYDlK2psmwK0qjkrSeWNgH/kt9wIQH3+6+A9Q2tUowlhbRp5fhrdrgG5GIPniT Vsdkvv/q7yBNVNIXOJfRPD1sU9uxxOO+36Yyu4wxXJJN+wB+D+9D+Dl9RHd5O/0DLz YQwGcfjtybKZUmKDvBafOnXsxff9KuHNkyxwVvjg= From: Sven Eckelmann To: b.a.t.m.a.n@lists.open-mesh.org Date: Tue, 21 Feb 2017 10:06:40 +0100 Message-Id: <20170221090640.14686-1-sven@narfation.org> X-Mailer: git-send-email 2.11.0 Subject: [B.A.T.M.A.N.] [PATCH] batman-adv: set git diff driver for C source code files X-BeenThere: b.a.t.m.a.n@lists.open-mesh.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: The list for a Better Approach To Mobile Ad-hoc Networking List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: The list for a Better Approach To Mobile Ad-hoc Networking Errors-To: b.a.t.m.a.n-bounces@lists.open-mesh.org Sender: "B.A.T.M.A.N" From: Jean Delvare Git can be told to apply language-specific rules when generating diffs. Enable this for C source code files (*.c and *.h) so that function names are printed right. Specifically, doing so prevents "git diff" from mistakenly considering unindented goto labels as function names. Signed-off-by: Jean Delvare [sven@narfation.org: Ported patch from linux.git] Signed-off-by: Sven Eckelmann --- .gitattributes | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitattributes b/.gitattributes index eeef3e0..1d2a7e9 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,2 +1,4 @@ /.gitignore export-ignore /.gitattributes export-ignore +*.c diff=cpp +*.h diff=cpp