From owner-freebsd-questions@FreeBSD.ORG Mon Jun 29 02:38:23 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CEEF0106564A for ; Mon, 29 Jun 2009 02:38:23 +0000 (UTC) (envelope-from vince@vjs.org) Received: from mail.vjs.org (static-71-126-154-132.washdc.fios.verizon.net [71.126.154.132]) by mx1.freebsd.org (Postfix) with ESMTP id 92F558FC0C for ; Mon, 29 Jun 2009 02:38:23 +0000 (UTC) (envelope-from vince@vjs.org) Received: from [192.168.5.248] (71.126.154.142) by mail.vjs.org with ESMTP (Eudora Internet Mail Server 3.1.5) for ; Sun, 28 Jun 2009 22:38:21 -0400 Mime-Version: 1.0 Message-Id: In-Reply-To: <4ad871310906281930k644b5d5fnf448decf8e489c4c@mail.gmail.com> References: <4A48252C.1090808@gmail.com> <4ad871310906281926i54fdac53u1d4681c8060e4d36@mail.gmail.com> <4A4826A5.6020506@gmail.com> <4ad871310906281930k644b5d5fnf448decf8e489c4c@mail.gmail.com> X-Mailer: Eudora 10.0b19 for Cray SV-2 (beta release), unregistered Date: Sun, 28 Jun 2009 22:38:20 -0400 To: freebsd-questions@freebsd.org From: Vince Sabio Content-Type: text/plain; charset="us-ascii" ; format="flowed" Subject: Re: what character is a physical newline X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Jun 2009 02:38:24 -0000 ** At 22:30 -0400 on 06/28/2009, Glen Barber wrote: >On Sun, Jun 28, 2009 at 10:27 PM, Aryeh M. Friedman wrote: > >> >>> What do you mean exactly? What language(s)? If I understand your >>> question correctly, the C / C++ / Java / PHP (and I think Perl) > >> 'newline' character is '\n' > > >> I meant what ascii character does \n actual correspond to (I assume but > > just making sure) No, CR is a carriage return, which is a \r in C, and is an ASCII 13 (hex 0D). "Newline" is a line feed (LF), which is a \n in C, and is an ASCII 10 (hex 0A) >Oh. IIRC, CR is the DOS way, and LR is the POSIX way. Not exactly; CRLF is the DOS way, CR is the Macintosh way, and LF is Unix/Posix. HTH. __________________________________________________________________________ Vince Sabio vince@vjs.org