| delorie.com/archives/browse.cgi | search |
| X-Recipient: | archive-cygwin AT delorie DOT com |
| X-Spam-Check-By: | sourceware.org |
| Message-ID: | <4714C9F3.8000706@chello.hu> |
| Date: | Tue, 16 Oct 2007 16:25:55 +0200 |
| From: | =?ISO-8859-2?Q?=C9rsek_L=E1szl=F3?= <lacos AT chello DOT hu> |
| User-Agent: | Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.8) Gecko/20060926 Debian/1.7.8-1sarge7.3.1 Mnenhy/0.7.4.0 |
| MIME-Version: | 1.0 |
| To: | cygwin AT cygwin DOT com |
| Subject: | "/" in filename confuses handling of spec. chars on non-managed mount |
| Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
| List-Id: | <cygwin.cygwin.com> |
| List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
| List-Archive: | <http://sourceware.org/ml/cygwin/> |
| List-Post: | <mailto:cygwin AT cygwin DOT com> |
| List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
| Sender: | cygwin-owner AT cygwin DOT com |
| Mail-Followup-To: | cygwin AT cygwin DOT com |
| Delivered-To: | mailing list cygwin AT cygwin DOT com |
Hi,
I'm running "CYGWIN_NT-5.1 1.5.24(0.156/4/2) 2007-01-31 10:57".
If I try to create a regular file with a colon (:) in its name, cygwin
refuses it with ENOENT (rightly so):
$ echo test >"a:b"
-bash: a:b: No such file or directory
However, if I put, in addition, a slash in the name:
(
set -e -C -x
mkdir test
df -m test
dd if=/dev/zero bs=4096 count=1024 >'test/a:b'
df -m test
ls -lsn 'test/a:b'
ls -lsn test
)
Standard output and error:
+ mkdir test
+ df -m test
Filesystem 1M-blocks Used Available Use% Mounted on
C:\cygwin 57232 9100 48132 16% /
(Redirection not shown below)
+ dd if=/dev/zero bs=4096 count=1024
1024+0 records in
1024+0 records out
4194304 bytes (4.2 MB) copied, 0.08 s, 52.4 MB/s
+ df -m test
Filesystem 1M-blocks Used Available Use% Mounted on
C:\cygwin 57232 9104 48128 16% /
+ ls -lsn test/a:b
4096 -rw------- 1 1003 513 4194304 Oct 16 16:14 test/a:b
No problem until this point, but:
+ ls -lsn test
total 0
0 -rw------- 1 1003 513 0 Oct 16 16:14 a
Shouldn't the redirection used with the dd command fail with ENOENT? The
file system containing the directory "test" is mounted without the
"managed" mount option.
This doesn't depend on the shell, I can reproduce it with a simple C
program.
Thank you
lacos
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |