Re: [PATCH 1/3] git send-email: avoid leaking directory file descriptors.
- From
Jeff King <peff@peff.net>
- Date
- Nov 2, 2008, 04:31 UTC
- Message-ID
- <20081102043120.GD5261@coredump.intra.peff.net>
- In-Reply-To
- <1225450632-7230-2-git-send-email-madcoder@debian.org>
On Fri, Oct 31, 2008 at 11:57:10AM +0100, Pierre Habouzit wrote:
> + closedir(DH);
Ugh. This is a great reason to use a scoped variable (like "my $dh), which will close automatically. Once upon a time I think you _had_ to use globs for this, but I think it has not been the case for some time (and I think we only support back to perl 5.6 these days). Can any perl gurus comment?
-Peff