This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author neologix
Recipients BreamoreBoy, ezio.melotti, neologix, python-dev, sbt, vstinner
Date 2014-07-29.17:29:39
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <CAH_1eM1Hh3nE0OxceZ5noy2W_ega=Kd8FuPe2RymsAR7EourEA@mail.gmail.com>
In-reply-to <1406583787.47.0.728227362981.issue18174@psf.upfronthosting.co.za>
Content
> Richard Oudkerk added the comment:
>
> I can't remember why I did not use fstat() -- probably it did not occur to me.

I probably have Alzeihmer, I was sure I heard a reasonable case for
dup() vs fstat().
The only thing I can think of is that fstat() can incur I/O, whereas
dup() shouldn't.

In any case, I too prefer fstat(), since it doesn't require creating a
new FD (which could fail with EMFILE/ENFILE), and is more logical.

The only comment I have about this patch is I think that the helper
function to detect the number of open FD might have its place in
test.support.
History
Date User Action Args
2014-07-29 17:29:39neologixsetrecipients: + neologix, vstinner, ezio.melotti, BreamoreBoy, python-dev, sbt
2014-07-29 17:29:39neologixlinkissue18174 messages
2014-07-29 17:29:39neologixcreate