From owner-svn-src-head@freebsd.org Sun Mar 12 03:49:07 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 0A617D08603; Sun, 12 Mar 2017 03:49:07 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id CBA801616; Sun, 12 Mar 2017 03:49:06 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v2C3n5qG025103; Sun, 12 Mar 2017 03:49:05 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v2C3n5gK025102; Sun, 12 Mar 2017 03:49:05 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201703120349.v2C3n5gK025102@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sun, 12 Mar 2017 03:49:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r315103 - head/usr.bin/diff X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Mar 2017 03:49:07 -0000 Author: bapt Date: Sun Mar 12 03:49:05 2017 New Revision: 315103 URL: https://svnweb.freebsd.org/changeset/base/315103 Log: Implement a stub --horizon-lines=NUM for compatibility with GNU diff3 some options of GNU diff3 would call diff with --horizon-lines, rcs is depending on that. Reported by: antoine Modified: head/usr.bin/diff/diff.c Modified: head/usr.bin/diff/diff.c ============================================================================== --- head/usr.bin/diff/diff.c Sun Mar 12 03:43:28 2017 (r315102) +++ head/usr.bin/diff/diff.c Sun Mar 12 03:49:05 2017 (r315103) @@ -54,6 +54,7 @@ enum { OPT_IGN_FN_CASE, OPT_NO_IGN_FN_CASE, OPT_NORMAL, + OPT_HORIZON_LINES, }; static struct option longopts[] = { @@ -83,6 +84,7 @@ static struct option longopts[] = { { "exclude", required_argument, 0, 'x' }, { "exclude-from", required_argument, 0, 'X' }, { "ignore-file-name-case", no_argument, NULL, OPT_IGN_FN_CASE }, + { "horizon-lines", required_argument, NULL, OPT_HORIZON_LINES }, { "no-ignore-file-name-case", no_argument, NULL, OPT_NO_IGN_FN_CASE }, { "normal", no_argument, NULL, OPT_NORMAL }, { "strip-trailing-cr", no_argument, NULL, OPT_STRIPCR }, @@ -225,6 +227,8 @@ main(int argc, char **argv) case 'x': push_excludes(optarg); break; + case OPT_HORIZON_LINES: + break; /* XXX TODO for compatibility with GNU diff3 */ case OPT_IGN_FN_CASE: ignore_file_case = 1; break;