[libxml2] 594874 Forgot an fclose in xmllint



commit 84bff68e03824d14b0e2cd58167303ec0b13c840
Author: Daniel Veillard <veillard redhat com>
Date:   Fri Sep 11 15:30:19 2009 +0200

    594874 Forgot an fclose in xmllint
    
    * xmllint.c: as pointed out by Pavol Rusnak, an fclose was missing
      in some case.

 xmllint.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/xmllint.c b/xmllint.c
index 25c6fb9..6e4138e 100644
--- a/xmllint.c
+++ b/xmllint.c
@@ -2175,6 +2175,8 @@ static void parseAndPrintFile(char *filename, xmlParserCtxtPtr rectxt) {
 			doc = NULL;
 		    }
 	        }
+                if (f != stdin)
+                    fclose(f);
 	    }
 	} else
 #endif /* LIBXML_PUSH_ENABLED */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]