File pointer leak
Vitezslav Crhonek <[email protected]> Tue, 16 Aug 2011 16:02:39 +0200
| Newsgroups | gmane.network.mrtg.devel |
|---|---|
| Message-ID | <[email protected]> |
This is a multi-part message in MIME format.
--------------040002020606030809080308
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Hi,
I'd like to propose you fix of a file pointer leak found by coverity
scan. Patch is attached.
Best regards,
Vitezslav Crhonek
--------------040002020606030809080308
Content-Type: text/plain;
name="mrtg-2.17.2-file-pointer-leak.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment; filename="mrtg-2.17.2-file-pointer-leak.patch"
--- rateup.c.orig 2011-08-16 15:42:40.820565704 +0200
+++ rateup.c 2011-08-16 15:44:15.859559278 +0200
@@ -1792,6 +1792,7 @@
if (!(cbuf = fread (buff, 1, LENGTH_OF_BUFF, fp)))
{
fprintf (stderr, "%s, %s ERROR: Parameters file empty\n", bufftime, program);
+ flcose (fp);
return (1);
}
fclose (fp);
--------------040002020606030809080308
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline
_______________________________________________
mrtg-developers mailing list
[email protected]
https://lists.oetiker.ch/cgi-bin/listinfo/mrtg-developers
--------------040002020606030809080308--