From owner-cvs-src@FreeBSD.ORG Sun May 2 04:25:38 2004 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 41ECE16A4D0; Sun, 2 May 2004 04:25:38 -0700 (PDT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3072143D66; Sun, 2 May 2004 04:25:38 -0700 (PDT) (envelope-from tjr@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.10/8.12.10) with ESMTP id i42BPbGe027011; Sun, 2 May 2004 04:25:37 -0700 (PDT) (envelope-from tjr@repoman.freebsd.org) Received: (from tjr@localhost) by repoman.freebsd.org (8.12.10/8.12.10/Submit) id i42BPbNk027010; Sun, 2 May 2004 04:25:37 -0700 (PDT) (envelope-from tjr) Message-Id: <200405021125.i42BPbNk027010@repoman.freebsd.org> From: "Tim J. Robbins" Date: Sun, 2 May 2004 04:25:37 -0700 (PDT) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/bin/ls extern.h ls.1 print.c util.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 May 2004 11:25:38 -0000 tjr 2004/05/02 04:25:37 PDT FreeBSD src repository Modified files: bin/ls extern.h ls.1 print.c util.c Log: Treat filenames as multibyte character strings (according to the current LC_CTYPE setting) when determining which characters are printable. This is an often-requested feature. Use wcwidth() to determine the number of column positions a character takes up, although there are still a few places left where we assume 1 byte = 1 column position, e.g. line-wrapping when handling the -m option. The error handling here is somewhat more complicated than usual: we do our best to show what we can of a filename in the presence of conversion errors, instead of simply aborting. Revision Changes Path 1.23 +1 -0 src/bin/ls/extern.h 1.80 +1 -5 src/bin/ls/ls.1 1.71 +2 -1 src/bin/ls/print.c 1.34 +130 -61 src/bin/ls/util.c