aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Meskes <meskes@postgresql.org>2013-09-08 12:49:54 +0200
committerMichael Meskes <meskes@postgresql.org>2013-09-08 13:13:03 +0200
commit3560dbcaac2f0ccb796512d6daf7ff3ea5bab5f0 (patch)
tree2c2ad43d10f007405a500b8873f012d292271d8e
parentfb843b2679d959a63f48c2f4ad52243053e1a5d4 (diff)
downloadpostgresql-3560dbcaac2f0ccb796512d6daf7ff3ea5bab5f0.tar.gz
postgresql-3560dbcaac2f0ccb796512d6daf7ff3ea5bab5f0.zip
Close file to no leak file descriptor memory. Found by Coverity.
-rw-r--r--src/interfaces/ecpg/preproc/pgc.l1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/interfaces/ecpg/preproc/pgc.l b/src/interfaces/ecpg/preproc/pgc.l
index 0cc7ba6c4c9..5abb74f14e5 100644
--- a/src/interfaces/ecpg/preproc/pgc.l
+++ b/src/interfaces/ecpg/preproc/pgc.l
@@ -1355,6 +1355,7 @@ parse_include(void)
/* if the command was "include_next" we have to disregard the first hit */
if (yyin && include_next)
{
+ fclose (yyin);
yyin = NULL;
include_next = false;
}