X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-1.5 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Message-ID: <4BA2B127.4080308@emc.com> Date: Thu, 18 Mar 2010 19:03:03 -0400 From: Douglas Seay User-Agent: Thunderbird 2.0.0.23 (X11/20090817) MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: cannot create files with trailing dots on network share Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: quoted-printable X-EMM-EM: Active X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: 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 I=92ve had some problems, and it looks like it boils down to handling .=20 (dot) characters. I created a little script to create some files with=20 dots in various places. This script works fine in my $HOME directory=20 (C:\cygwin\home\SEAYD). The name is wrong when the last character of=20 the filename is a dot and subdir is on a network share (H: in this=20 case). The rest of the file operations seem to work because when I cat=20 them, you can see the file name inside the body (yes, I left of the \n). Is there a known work around for this? > /cygdrive/h/foo> ./fubar > mkdir subdir > create subdir/none > create subdir/in.middle > create subdir/.before > create subdir/after. > create subdir/.every.where. > finished successfully > /cygdrive/h/foo> ls -al subdir > total 5120 > drwxr-xr-x+ 1 ???????? ???????? 0 2010-03-18 18:31 . > drwxrwxrwx 7 ???????? ???????? 0 2010-03-18 18:31 .. > -rwxr--r-- 1 ???????? ???????? 7 2010-03-18 18:31 .before > -rwxr--r-- 1 ???????? ???????? 6 2010-03-18 18:31 ARO60A~X > -rwxr--r-- 1 ???????? ???????? 13 2010-03-18 18:31 _IQDF8~T > -rwxr--r-- 1 ???????? ???????? 9 2010-03-18 18:31 in.middle > -rwxr--r-- 1 ???????? ???????? 4 2010-03-18 18:31 none > /cygdrive/h/foo> cat subdir/ARO60A~X > after./cygdrive/h/foo> cat subdir/_IQDF8~T > .every.where./cygdrive/h/foo> A bit more background: I=92m trying to use cvs and I=92m getting errors. I= =20 cannot tell if this is the same issue as is going back and forth on the=20 mailing list right now, or if I=92ve bumped into something else. When I=20 ran my =93cvs co=94 with strace, I see what appears to be CVS getting the= =20 files in temp names that have a lot of dots, and then doing a rename=20 after the file has downloaded. The download seems to work, but it puts=20 the file in an incorrectly named temp file, and then the rename to the=20 proper name is what fails and causes the error. Since that doesn=92t=20 really sound cvs specific (ie =96 it should work), I went off and=20 reproduced it outside of CVS. In case I=92m not clear, this is cygwin 1.7.1. Mostly I=92ve been using=20 Server 2008. - doug Here is the perl script =93fubar=94 that I used to generate these files,=20 just in case it matters. It really isn't fancy. > #!/bin/perl >=20 > use strict; > use warnings; >=20 > my $SUBDIR =3D 'subdir'; > my @TEST_CASES =3D qw( none > in.middle > .before > after. > .every.where. > ); >=20 > print "mkdir $SUBDIR\n"; > mkdir $SUBDIR unless ( -d $SUBDIR ); > chdir $SUBDIR or die "chdir($SUBDIR) failed: $!"; >=20 > foreach my $filename ( @TEST_CASES ) { > print "create $SUBDIR/$filename\n"; > open TESTCASE, ">$filename" or die "error opening $filename: $!"; > print TESTCASE $filename; > close TESTCASE; > } >=20 > print "finished successfully\n"; -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple