From owner-freebsd-questions@FreeBSD.ORG Tue Feb 8 02:12:38 2005 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EE99A16A4CE for ; Tue, 8 Feb 2005 02:12:37 +0000 (GMT) Received: from mailgate.bytemobile.com (mailgate.bytemobile.com [209.10.233.248]) by mx1.FreeBSD.org (Postfix) with ESMTP id CCCBA43D39 for ; Tue, 8 Feb 2005 02:12:37 +0000 (GMT) (envelope-from keramida@linux.gr) From: "Giorgos Keramidas" To: Date: Mon, 7 Feb 2005 18:12:37 -0800 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook, Build 10.0.4024 In-Reply-To: <1667502496.20050208025619@wanadoo.fr> Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409 X-OriginalArrivalTime: 08 Feb 2005 02:12:37.0152 (UTC) FILETIME=[A8AA0A00:01C50D83] Subject: RE: Another grep question X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Feb 2005 02:12:38 -0000 Anthony Atkielski wrote: > Does anyone know why > > grep -R "\0x93" /www/htdocs > > turns up only binary files, even when I know there are text > files in the directory that contain this character? Is > there something special about the way I specify the search > string that causes grep to behave differently? When I > specify an 8-bit character like this alone for a > search, it finds only binary files, even though this is a text > character--as if it is looking at the search string and > deciding that I want to search only binary files. It may not be related to what you are seeing, but grep(1) is locale-aware. What it considers a "text" character depends on the current locale settings. In my account, which has a Greek locale setup, it will consider all Greek 8-bit characters as text. This e-mail and any attachments may contain confidential and privileged information. If you are not the intended recipient, please notify the sender immediately by return e-mail, do not forward this email to any other person, delete this e-mail and destroy all copies. Any dissemination or use of this information by a person other than the intended recipient is unauthorized and may be illegal.