From owner-freebsd-questions@freebsd.org Sun Jun 26 18:44:50 2016 Return-Path: Delivered-To: freebsd-questions@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 4DEBBB818C5 for ; Sun, 26 Jun 2016 18:44:50 +0000 (UTC) (envelope-from wblock@wonkity.com) Received: from wonkity.com (wonkity.com [67.158.26.137]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "wonkity.com", Issuer "wonkity.com" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 1D53F24E3; Sun, 26 Jun 2016 18:44:49 +0000 (UTC) (envelope-from wblock@wonkity.com) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.15.2/8.15.2) with ESMTPS id u5QIim2m088303 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Sun, 26 Jun 2016 12:44:48 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.15.2/8.15.2/Submit) with ESMTP id u5QIimZC088300; Sun, 26 Jun 2016 12:44:48 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Sun, 26 Jun 2016 12:44:48 -0600 (MDT) From: Warren Block To: Matthew Seaman cc: freebsd-questions@freebsd.org Subject: Re: grep and anchoring In-Reply-To: <9fc6d5df-108b-5663-5a31-92ca915a9604@FreeBSD.org> Message-ID: References: <20232C89-B821-41EC-9188-C2A19C679BD8@danieldk.eu> <20160626163411.d05f863e.freebsd@edvax.de> <362EE01F-4B49-4ADB-A3A6-43F852FFF87F@danieldk.eu> <9fc6d5df-108b-5663-5a31-92ca915a9604@FreeBSD.org> User-Agent: Alpine 2.20 (BSF 67 2015-01-07) MIME-Version: 1.0 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (wonkity.com [127.0.0.1]); Sun, 26 Jun 2016 12:44:48 -0600 (MDT) Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8BIT X-Content-Filtered-By: Mailman/MimeDel 2.1.22 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 26 Jun 2016 18:44:50 -0000 On Sun, 26 Jun 2016, Matthew Seaman wrote: > On 26/06/2016 15:44, Daniël de Kok wrote: >> Note the anchoring (^), the pattern should only match any four characters at the beginning of the line, so the expected output is ‘1234’ and nothing more. ‘ 123' and '4 12' are not at the beginning of the line and should consequently not be printed to stdout. >> >> For comparison, the output of a recent GNU grep: >> >> — >> % echo "1234 1234 1234" | grep -o '^....' >> 1234 >> — > > You are completely correct -- this is a bug in grep(1) on FreeBSD. In > all current releases including the upcoming 11.0-RELEASE grep is > actually GNU grep version 2.1.5. However, the same bug occurs in > bsdgrep(1): > > % echo 1234 1234 1234 | bsdgrep -o '^....' > 1234 > 123 > 4 12 Yay for compatibility! :) From owner-freebsd-questions@freebsd.org Mon Jun 27 01:31:19 2016 Return-Path: Delivered-To: freebsd-questions@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 AB006A79C25 for ; Mon, 27 Jun 2016 01:31:19 +0000 (UTC) (envelope-from gregory.orange@calorieking.com) Received: from pandora.au.calorieking.net (mail.au.calorieking.net [115.70.179.114]) (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 5AFF424C9 for ; Mon, 27 Jun 2016 01:31:18 +0000 (UTC) (envelope-from gregory.orange@calorieking.com) Received: from pandora.au.calorieking.net (localhost [127.0.0.1]) by pandora.au.calorieking.net (Postfix) with ESMTP id F212110C for ; Mon, 27 Jun 2016 09:24:30 +0800 (WST) X-Virus-Scanned: amavisd-new at calorieking.com Received: from pandora.au.calorieking.net ([127.0.0.1]) by pandora.au.calorieking.net (mail.au.calorieking.net [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id kwVQ6_yPSF3f for ; Mon, 27 Jun 2016 09:24:26 +0800 (WST) Received: from [192.168.2.118] (freia.ne1.au.calorieking.net [192.168.2.118]) by pandora.au.calorieking.net (Postfix) with ESMTPSA id 9C4F5C8 for ; Mon, 27 Jun 2016 09:24:26 +0800 (WST) Subject: Re: freebsd-update && locally modified files To: freebsd-questions@freebsd.org References: <20160623151128.GA25400@ice.42.org> From: Gregory Orange Message-ID: <57708049.8040509@calorieking.com> Date: Mon, 27 Jun 2016 09:24:25 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.8.0 MIME-Version: 1.0 In-Reply-To: <20160623151128.GA25400@ice.42.org> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 27 Jun 2016 01:31:19 -0000 Hi Stefan, On 23/06/16 23:11, Stefan `Sec` Zehl wrote: > | The following files are affected by updates, but no changes have > | been downloaded because the files have been modified locally: > | /etc/mail/freebsd.cf > | /etc/mail/freebsd.submit.cf > | /etc/mail/sendmail.cf > | /etc/mail/submit.cf > | /var/db/mergemaster.mtree > > The obvious solution of deleting them and letting freebsd-update install > run did not restore those files. On the rare occasion that happens, I tend to grab the files from a pristine installation and put them in place, as well as copies (with a .dist suffix) in case it recurs. Greg.