This is the mail archive of the
cygwin-patches@cygwin.com
mailing list for the Cygwin project.
[Patch] cygcheck: ``pclose'' what was ``popen''ed.
- From: Bas van Gompel <cygwin-patches dot buzz at bavag dot tmfweb dot nl>
- To: cygwin-patches at cygwin dot com
- Date: Wed, 29 Sep 2004 02:56:51 +0200 (MET DST)
- Subject: [Patch] cygcheck: ``pclose'' what was ``popen''ed.
- Organisation: Ehm...
- Reply-to: cygwin-patches mailing-list <cygwin-patches at cygwin dot com>
Hi,
Another trivial (IMO) patch. What was opened by ``popen'', needs
closing by ``pclose''.
ChangeLog-entry:
2004-09-29 Bas van Gompel <cygwin-patch.buzz@bavag.tmfweb.nl>
* cygcheck.cc (pretty_id): Close pipe.
--- src/winsup/utils/cygcheck.cc 21 Mar 2004 17:58:14 -0000 1.43
+++ src/winsup/utils/cygcheck.cc 28 Sep 2004 20:42:32 -0000
@@ -793,6 +793,7 @@ pretty_id (const char *s, char *cygwin,
static char empty[] = "";
buf[0] = '\0';
fgets (buf, sizeof (buf), f);
+ pclose(f);
char *uid = strtok (buf, ")");
if (uid)
uid += strlen ("uid=");
L8r.
Buzz.
--
) | | ---/ ---/ Yes, this | This message consists of true | I do not
-- | | / / really is | and false bits entirely. | mail for
) | | / / a 72 by 4 +-------------------------------+ any1 but
-- \--| /--- /--- .sigfile. | |perl -pe "s.u(z)\1.as." | me. 4^re