aboutsummaryrefslogtreecommitdiff
path: root/ui-snapshot.c
diff refs
from: back
to: back
| flip
diff options
context:
space:
mode:
Diffstat (limited to 'ui-snapshot.c')
-rw-r--r--ui-snapshot.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/ui-snapshot.c b/ui-snapshot.c
index 7a597ff..966a140 100644
--- a/ui-snapshot.c
+++ b/ui-snapshot.c
@@ -82,13 +82,7 @@ static int make_snapshot(const struct cgit_snapshot_format *format,
return 1;
}
memset(&args, 0, sizeof(args));
- if (prefix) {
- args.base = fmt("%s/", prefix);
- args.baselen = strlen(prefix) + 1;
- } else {
- args.base = "";
- args.baselen = 0;
- }
+ args.base = fmt("%s/", prefix);
args.tree = commit->tree;
args.time = commit->date;
ctx.page.mimetype = xstrdup(format->mimetype);