[tracker/tracker-0.10] tracker-extract-gif: Fix file descriptor leak in error case



commit 69157ffbf92d817532a2599905a146264bb4773c
Author: JÃrg Billeter <j bitron ch>
Date:   Tue Sep 27 16:50:04 2011 +0200

    tracker-extract-gif: Fix file descriptor leak in error case

 src/tracker-extract/tracker-extract-gif.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
---
diff --git a/src/tracker-extract/tracker-extract-gif.c b/src/tracker-extract/tracker-extract-gif.c
index 725a31b..ec6ed47 100644
--- a/src/tracker-extract/tracker-extract-gif.c
+++ b/src/tracker-extract/tracker-extract-gif.c
@@ -576,6 +576,7 @@ extract_gif (const gchar          *uri,
 
 	if ((gifFile = DGifOpenFileHandle (fd)) == NULL) {
 		PrintGifError ();
+		close (fd);
 		return;
 	}
 



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