Diff options
authorBryce Kwon <bryce@brycekwon.com>
committerBryce Kwon <bryce@brycekwon.com>
commit
parent
tree
download
Stop copying a snapshot's type and name
Diffstat (limited to 'source/ui-snapshot.c')
-rw-r--r--source/ui-snapshot.c8
1 file changed, 4 insertions, 4 deletions
diff --git a/source/ui-snapshot.c b/source/ui-snapshot.c
index ffd0b0b..321bf61 100644
--- a/source/ui-snapshot.c
+++ b/source/ui-snapshot.c
@@ -245,8 +245,8 @@ static void send_snapshot(const struct cgit_snapshot_format *format, const char
format->compressor[0]);
return;
}
- ctx.page.mimetype = xstrdup(format->mimetype);
- ctx.page.filename = xstrdup(filename);
+ ctx.page.mimetype = format->mimetype;
+ ctx.page.filename = filename;
cgit_print_http_headers();
init_archivers();
// The archiver reads its arguments as a command line, so it gets the
@@ -285,8 +285,8 @@ static void send_sig(const struct cgit_snapshot_format *format, const char *hex,
}
ctx.page.untrusted = 1;
- ctx.page.mimetype = xstrdup("application/pgp-signature");
- ctx.page.filename = xstrdup(sig_filename);
+ ctx.page.mimetype = "application/pgp-signature";
+ ctx.page.filename = sig_filename;
cgit_print_http_headers();
html_raw(buf, size);