]> git.cameronkatri.com Git - cgit.git/commitdiff
ui-blob: fix resource leak: free before return
authorChristian Hesse <mail@eworm.de>
Sat, 10 Oct 2015 14:56:23 +0000 (16:56 +0200)
committerJason A. Donenfeld <Jason@zx2c4.com>
Sat, 10 Oct 2015 19:39:25 +0000 (21:39 +0200)
Coverity-id: 13944
Signed-off-by: Christian Hesse <mail@eworm.de>
ui-blob.c

index 70a671e6ca02b30e100f697994033aecac775ef7..1ded8397f5d59d03cd8ecb17705c0c9f69e5e881 100644 (file)
--- a/ui-blob.c
+++ b/ui-blob.c
@@ -171,4 +171,5 @@ void cgit_print_blob(const char *hex, char *path, const char *head, int file_onl
        ctx.page.filename = path;
        cgit_print_http_headers();
        html_raw(buf, size);
+       free(buf);
 }