Skip to content
Tcl Source Code View Ticket
Login

View Ticket

glob with unreadable directory

Open3531271fffffffffffffffffffffffffffffffffCreated 15 years agoUpdated 15 years ago
Descriptionplain2012-06-01 08:11:37
glob returns an error if the directory is unreadable.  It would be nice if there is at least an option to silently ignore unreadable directories.  I am using ActiveState Tcl 8.5.11.1 on linux.

> ls -ld tmp*
d--------- 2 user group 4096 2012-06-01 00:43 tmp/
drwxr-xr-x 2 user group 4096 2012-06-01 01:03 tmp2/

> tclsh
> puts $tcl_patchLevel
8.5.11

> glob -nocomplain -type f -- */*.c
couldn't read directory "tmp/": permission denied
> glob -nocomplain -type f -- tmp2/*.c
tmp2/a.c
Log in (anonymous is fine) to add a comment.