From owner-freebsd-current@FreeBSD.ORG Mon Jan 17 05:28:21 2005 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E9DD116A4CF for ; Mon, 17 Jan 2005 05:28:21 +0000 (GMT) Received: from wproxy.gmail.com (wproxy.gmail.com [64.233.184.206]) by mx1.FreeBSD.org (Postfix) with ESMTP id 746D443D41 for ; Mon, 17 Jan 2005 05:28:21 +0000 (GMT) (envelope-from chiahsing@gmail.com) Received: by wproxy.gmail.com with SMTP id 68so700848wri for ; Sun, 16 Jan 2005 21:28:20 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:references; b=CvYPal2nDlp9tRlNbzAI1FNClwPoSA/qUWFqQ7nPQ0y0aBlVYwFXnaO7lSv2wJfERufC76rDz1zNxpDAll1j/BtliHYRPFZWT8garqfVmFuUNi7gWWU9NSPgH1e0E3MeAGQHPkC0+CFJZ3AtixZJeag8rG7LqVrOELKGzy7hCyI= Received: by 10.54.40.34 with SMTP id n34mr131592wrn; Sun, 16 Jan 2005 21:28:20 -0800 (PST) Received: by 10.54.31.21 with HTTP; Sun, 16 Jan 2005 21:28:20 -0800 (PST) Message-ID: Date: Sun, 16 Jan 2005 21:28:20 -0800 From: David Yu To: Christopher Vance In-Reply-To: <20050117032255.GC630@nu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit References: <20050117020039.GB630@nu.org> <20050117032255.GC630@nu.org> cc: freebsd-fs@freebsd.org cc: freebsd-current@freebsd.org Subject: Re: NTFS unicode converting problem X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: David Yu List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Jan 2005 05:28:22 -0000 The problem is that I have to default XLAT16_ACCEPT_3BYTE_CHR in both libkiconv and module/libiconv.ko. Though it works, I don't it is a good way to use translation table since UCS-2 to UTF-8 is so straightforward. Maybe we need to write a new kernel side iconv converter for this? I have no idea about those iconv codes in the kernel at all. On Mon, 17 Jan 2005 14:22:55 +1100, Christopher Vance wrote: > On Sun, Jan 16, 2005 at 06:25:52PM -0800, David Yu wrote: > >In my case, those Chinese filenames are still in UCS-2LE, and all > >characters are in plane 0. I tried to modify codes so that it can > >directly store the conversion result into the dirent structure, but > >the convchr() funtion failed everytime for Chinese character while > >there is no problem with Ascii characters. I thought converting from > >UCS-2 to UTF-8 should be very easy? > > Maybe the conversion routine disagrees with you about byte order? > > -- > Christopher Vance >