From mboxrd@z Thu Jan 1 00:00:00 1970 From: cgit at cryptocrack.de (Lukas Fleischer) Date: Sat, 17 Jan 2015 14:54:31 +0100 Subject: [PATCH] Add Etags for snapshots Message-ID: <1421502871-7376-1-git-send-email-cgit@cryptocrack.de> From: Janus --- Sending this on behalf of Janus who cannot post to the list for some reason. ui-snapshot.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ui-snapshot.c b/ui-snapshot.c index ea77eb4..cb34f4b 100644 --- a/ui-snapshot.c +++ b/ui-snapshot.c @@ -119,6 +119,7 @@ static int make_snapshot(const struct cgit_snapshot_format *format, cgit_print_error("Not a commit reference: %s", hex); return 1; } + ctx.page.etag = sha1_to_hex(sha1); ctx.page.mimetype = xstrdup(format->mimetype); ctx.page.filename = xstrdup(filename); cgit_print_http_headers(); -- 2.2.2