diff options
author | rsc <devnull@localhost> | 2005-01-30 19:45:08 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2005-01-30 19:45:08 +0000 |
commit | 98e19d6df6ecb636f85d11a52065a5f6c51c1ad9 (patch) | |
tree | d0888deec52c4ebc00177d42bc9779faa62c3572 /src/cmd/core.c | |
parent | 6bc22c7d87df65a5fc380cbaf67c5e5a6456a2de (diff) | |
download | plan9port-98e19d6df6ecb636f85d11a52065a5f6c51c1ad9.tar.gz plan9port-98e19d6df6ecb636f85d11a52065a5f6c51c1ad9.tar.bz2 plan9port-98e19d6df6ecb636f85d11a52065a5f6c51c1ad9.zip |
do not readdir files - from zoltan jarai
Diffstat (limited to 'src/cmd/core.c')
-rw-r--r-- | src/cmd/core.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/cmd/core.c b/src/cmd/core.c index a0021a0a..be3fe8ae 100644 --- a/src/cmd/core.c +++ b/src/cmd/core.c @@ -68,8 +68,11 @@ coreall(char *name) fprint(2, "%s: %r\n", name); return; } - if((d->mode&DMDIR) == 0) + if((d->mode&DMDIR) == 0){ + free(d); corefile(name, 1); + return; + } free(d); if((fd = open(name, OREAD)) < 0){ fprint(2, "open %s: %r\n", name); |