delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2000/12/17/20:15:11

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
From: "Lothan" <lothan AT newsguy DOT com>
To: "Cygwin" <cygwin AT cygwin DOT com>
Subject: cvs
Date: Sun, 17 Dec 2000 17:14:28 -0800
Message-ID: <EJEMICJMAGCJAPFPGPLGGEHPCFAA.lothan@newsguy.com>
MIME-Version: 1.0
X-Priority: 3 (Normal)
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0)
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400
Importance: Normal

I'm using Cygwin 1.1.6 (full install from scratch using the setup tool) on
Windows 2000 SP1 and am attempting to check out the gnome sources from
:pserver:anonymous AT anoncvs DOT gnome DOT org:/cvs/gnome. Everything was working well
until it got to the gdm folder, at which point it stopped with the error
unable to rename "gdm/config/.new.:0" to ":0". This brought up an
interesting problem because bash (ls -al) could not see any files in the
config directory even though Windows Explorer clearly showed a file named
".new.". Even funnier is that neither bash, Windows Exploroer nor a windows
command prompt could delete this file; and neither bash nor Windows Explorer
could remove the directory (Explorer complained that it couldn't read the
source file or the disk). I finally managed to get the directory deleted
from a Windows command prompt.

lothan AT LOTHAN2 ~/test
$ ls -a
.        ..       .new.    a.exe    test.c   test2.c

lothan AT LOTHAN2 ~/test
$ ls -al
ls: .new.: No such file or directory
total 13
drwxr-xr-x   2 lothan   None            0 Dec 17 17:10 .
drwxr-xr-x   4 lothan   None         4096 Dec 17 16:24 ..
-rwxr-xr-x   1 lothan   None        17742 Dec 17 17:10 a.exe
-rw-r--r--   1 lothan   None          196 Dec 17 16:58 test.c
-rw-r--r--   1 lothan   None           93 Dec 17 17:10 test2.c

I can duplicate the behavior quite easily using this code:

#include <sys/unistd.h>
#include <sys/fcntl.h>

main()
{
    int f;

    /* open() also works */
    f = creat(".new.:0", O_RDWR | O_CREAT);
    write(f, "this is a test\n", 15);
    close(f);
}

WARNING: run the resulting executable in an empty directory. The only way I
can delete the file is to delete the directory from a Windows command prompt
(rd test). I did try unlink(".new.:0") but it failed.


--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019