Jim Meyering wrote:
Here's another corner-case fix.
I'll push something like this as soon as I've updated NEWS
and added a test.
From 26a1306a0a9028eceed388dad0d8916aeeb00233 Mon Sep 17 00:00:00 2001
From: Jim Meyering meyer...@redhat.com
Date: Mon, 28 Sep 2009 20:24:41 +0200
Here's a more
Pádraig Brady wrote:
Jim Meyering wrote:
Jim Meyering wrote:
Here's a fix to make ls -LR work the same way Solaris 10's /bin/ls
does in the presence of a cycle.
It makes sense to exit(2) along with the printed error.
The patch looks good.
Thanks for the review.
Jim Meyering wrote:
Nearly missed this one.
ls initializes a struct stat to all NUL bytes.
It calls stat or lstat on a dangling symlink, and that fails.
ls then tests stat.st_ino.
Sometimes, it's 0, but sometimes it's the inode of the symlink,
possibly depending on how the package was
Pádraig Brady wrote:
Jim Meyering wrote:
Nearly missed this one.
ls initializes a struct stat to all NUL bytes.
It calls stat or lstat on a dangling symlink, and that fails.
ls then tests stat.st_ino.
Sometimes, it's 0, but sometimes it's the inode of the symlink,
possibly depending on
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
According to Jim Meyering on 9/29/2009 5:13 AM:
- /* The failed stat/lstat may have modified f-stat. Clear it,
- since we may use at least its st_ino member, e.g.,
- when trying to print the inode of dangling
Eric Blake wrote:
According to Jim Meyering on 9/29/2009 5:13 AM:
- /* The failed stat/lstat may have modified f-stat. Clear it,
- since we may use at least its st_ino member, e.g.,
- when trying to print the inode of dangling symlink:
- mkdir d;
Eric Blake wrote:
According to Jim Meyering on 9/29/2009 5:13 AM:
- /* The failed stat/lstat may have modified f-stat. Clear it,
- since we may use at least its st_ino member, e.g.,
- when trying to print the inode of dangling symlink:
- mkdir d;
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
According to Jim Meyering on 9/15/2009 5:49 AM:
But couldn't, because stat didn't accept - as meaning standard input.
Here's a patch to make it do that (and make the above print what's displayed):
This is just FYI.
Of course I'll add the usual
Eric Blake wrote:
According to Jim Meyering on 9/15/2009 5:49 AM:
But couldn't, because stat didn't accept - as meaning standard input.
Here's a patch to make it do that (and make the above print what's
displayed):
This is just FYI.
Of course I'll add the usual NEWS, log and tests and
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
According to Jim Meyering on 9/29/2009 6:44 AM:
stat has two modes of operation: the default is to interpret each
argument as a file on which to call stat or lstat.
Then there's the --file-system (-f) option.
The - == stdin approach makes sense
Eric Blake wrote:
According to Jim Meyering on 9/29/2009 6:44 AM:
stat has two modes of operation: the default is to interpret each
argument as a file on which to call stat or lstat.
Then there's the --file-system (-f) option.
The - == stdin approach makes sense for the first case.
Since I
Per recent discussion, here's all but the documentation update.
From a033e28737c1f6320bfc56b484253b61051bad85 Mon Sep 17 00:00:00 2001
From: Jim Meyering meyer...@redhat.com
Date: Tue, 15 Sep 2009 23:07:18 +0200
Subject: [PATCH] stat: interpret - as standard input
* src/stat.c (do_stat):
Jim Meyering jim at meyering.net writes:
But how would you make it work *with* -f? You don't know the path of the
file used to create stdin (and in the case of a pipe, there is no path),
There is no need for an actual file name, since fstatfs
takes a file descriptor. Of course, there's
Eric Blake wrote:
Jim Meyering jim at meyering.net writes:
But how would you make it work *with* -f? You don't know the path of the
file used to create stdin (and in the case of a pipe, there is no path),
There is no need for an actual file name, since fstatfs
takes a file descriptor. Of
Jim Meyering j...@meyering.net writes:
However, I'm a little reluctant to change back.
Let's wait a day or two, in case Paul Eggert has an objection.
Here are some objections to the change, under the assumption that
we're in a poorly-configured environment (as the behavior is
unaffected in
All,
Woudl this tool be useful/interesting to the coreutils group? It's not
in C,
but has some unique/novel features. When I saw the program uniq, I did a man
and saw this list. I thought it might be worth a look for the group. If you
are interested, I wrote it in python over the last
16 matches
Mail list logo