Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Date: Wed, 3 Jul 2002 00:38:25 +0300 From: Ville Herva To: cygwin AT cygwin DOT com Subject: Re: Accessing filenames with different charsets Message-ID: <20020702213825.GF9092@niksula.cs.hut.fi> Reply-To: cygwin AT cygwin DOT com, v AT iki DOT fi References: <20020701085851 DOT GD9092 AT niksula DOT cs DOT hut DOT fi> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020701085851.GD9092@niksula.cs.hut.fi> User-Agent: Mutt/1.3.25i On Mon, Jul 01, 2002 at 11:58:51AM +0300, you [Ville Herva] wrote: > Sorry if this has already been discussed, but I couldn't find it in the > archive nor in the FAQ... > > If I have a file name with Russian characters in it, cygwin is unable to > access it: > > > ls > ????.TEST > > (Russian characters are shown as '?' in directory listing, but ls does find > the file). > > If I try to access it, however, open fails: > > > touch * > touch: '????.TEST': no such file or directory > > same deal with less, cp, rm, rsync etc. Okay, it seems cygwin readdir() returns the filenames as "????.TEST" (where ?:s are really ?:s (ascii 0x3f)). Looking at fhandler_disk_file.cc, this can't be caused by much else than by FindFirstFileA() returning "????.TEST". And indeed, if made a little non-unicode test program, that called FindFirstFile, and it returned "????.TEST" ("\0x3f\0x3f\0x3f\0x3f.TEST"). To access the file, the wide char versions of Find*File() functions would propably have to be used (or is there another way?). I can't no idea how this could be integrated into the cygwin framework... Any ideas? -- v -- v AT iki DOT fi -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/