From 1723e6dc4f8eff8aaa1e0f7560800c76e85f3009 Mon Sep 17 00:00:00 2001 From: Dave Reisner Date: Thu, 18 Aug 2011 12:18:39 -0400 Subject: lib/dload: prevent possible NULL dereference Signed-off-by: Dave Reisner Signed-off-by: Dan McGee --- lib/libalpm/dload.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/libalpm') diff --git a/lib/libalpm/dload.c b/lib/libalpm/dload.c index 5464740a..37989370 100644 --- a/lib/libalpm/dload.c +++ b/lib/libalpm/dload.c @@ -396,7 +396,7 @@ cleanup: } } - if((ret == -1 || dload_interrupted) && should_unlink) { + if((ret == -1 || dload_interrupted) && should_unlink && tempfile) { unlink(tempfile); } -- cgit v1.2.3-70-g09d2