This is the mail archive of the cygwin@sources.redhat.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: possible bug with find


WHAT?!: e.g. HP-UX 10.20 happens to have

$ ll /usr/*h
lr-xr-xr-t   1 root       sys             14 Jul 13  1998 /usr/keysh ->
/usr/lib
/keysh

thus

$ (cd /usr;find include -name *h)

finds nothing, since find is really invoked as

$ (cd /usr;find include -name keysh)

So unprotected * is passed only literally if the shell
FAILS to expand the wildcard in the current dir!

It needs to be quoted to work:

$ (cd /usr;find include -name '*h'|head -3)
include/sys/cmn_err.h
include/sys/sad.h
include/sys/stream.h


Bye, Heribert (heribert_dahms@icon-gmbh.de)

> -----Original Message-----
> From:	Gerrit Peter Haase [SMTP:gerrit@familiehaase.de]
> Sent:	Tuesday, January 16, 2001 22:56
> To:	Heribert Dahms
> Cc:	'Timothee Besset'; cygwin@cygwin.com
> Subject:	Re: possible bug with find
> 
> Heribert Dahms schrieb:
> > 
> > Hi Timo,
> > 
> > no bug, user error: On every *ix you normally need quotation to prevent
> the
> > shell from file globbing (wildcard expansion) before involing programs,
> like
> > 
> > find GtkRadiant -iname '*.cpp' -print
> 
> WHAT???
> 
> $ find include -iname *.h -print
> 
> include/ansidecl.h
> include/bfd.h
	[Heribert]  [snip]


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]