This is the mail archive of the
mailing list for the Cygwin project.
RE: Data streams being treated as files in Cygwin
- From: Igor Peshansky <pechtcha at cs dot nyu dot edu>
- To: Dave Korn <dave dot korn at artimi dot com>
- Cc: cygwin at cygwin dot com
- Date: Thu, 11 May 2006 11:24:39 -0400 (EDT)
- Subject: RE: Data streams being treated as files in Cygwin
- References: <003a01c6750e$19c1a1b0$a501a8c0@CAM.ARTIMI.COM>
- Reply-to: cygwin at cygwin dot com
On Thu, 11 May 2006, Dave Korn wrote:
> On 11 May 2006 16:11, Igor Peshansky wrote:
> > On Thu, 11 May 2006, Dave Korn wrote:
> >> On 11 May 2006 16:00, Igor Peshansky wrote:
> >>> On Thu, 11 May 2006, Dave Korn wrote:
> >>>> Cygwin's file handling relies on the underlying facilities of the
> >>>> Windows O/S, for the most part.
> >>> Yes, and that leads to some funny behavior -- see below.
> >>> Interestingly enough:
> >>> $ echo "BLAH" > a:b
> >>> bash: a:b: No such file or directory
> >> Perhaps you forgot to put a floppy in the drive?
> > Gee, you think so? :-)
> Hmmm... let's try....
> dk@rainbow /test/ads> echo "blah" > a:b
> bash: a:b: No medium found
> dk@rainbow /test/ads>
> OK, I think I get it now. Let me re-word my observation:
> >> Perhaps you forgot to put the floppy drive in?
Yep, yep. But I knew exactly what the issue was -- just trying to make
the comment below (first sentence).
> > The point I was making was that Windows isn't consistent about treating
> > filenames as streams vs. disk references, due to the reuse of the ':'
> > character. I'm guessing it would be possible to add streams to a file
> > called 'a', but not through the interfaces used by Cygwin.
> Gee, you think not? :-)
> dk@rainbow /test/ads> echo "blah" > ./a:b
> dk@rainbow /test/ads> ls -la a
> -rw-r--r-- 1 dk Domain Users 0 May 11 16:16 a
> dk@rainbow /test/ads>
...as I found out after about 15 seconds after hitting "Send", by reading
the main NTFS streams entry on MSDN. It's amasing what a little RTFM
*before sending the message* can do... :-)
|\ _,,,---,,_ firstname.lastname@example.org | email@example.com
ZZZzz /,`.-'`' -. ;-;;,_ Igor Peshansky, Ph.D. (name changed!)
|,4- ) )-,_. ,\ ( `'-' old name: Igor Pechtchanski
'---''(_/--' `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-. Meow!
"Las! je suis sot... -Mais non, tu ne l'es pas, puisque tu t'en rends compte."
"But no -- you are no fool; you call yourself a fool, there's proof enough in
that!" -- Rostand, "Cyrano de Bergerac"
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html