Commit f488e73cc64d66f43bd34fd8253e94cf7545aa88

Stefan Sperling 2019-04-11T22:01:15

fix objpath memleak in got_object_blob_create()

1
2
3
4
5
6
7
8
9
10
11
12
diff --git a/lib/object_create.c b/lib/object_create.c
index b7496e3..9a45cab 100644
--- a/lib/object_create.c
+++ b/lib/object_create.c
@@ -152,6 +152,7 @@ got_object_blob_create(struct got_object_id **id, struct got_repository *repo,
 	}
 done:
 	free(header);
+	free(objpath);
 	if (outpath) {
 		if (unlink(outpath) != 0 && err == NULL)
 			err = got_error_from_errno();