-rw-r--r-- | ui-snapshot.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/ui-snapshot.c b/ui-snapshot.c index 966a140..7a597ff 100644 --- a/ui-snapshot.c +++ b/ui-snapshot.c @@ -84,3 +84,9 @@ static int make_snapshot(const struct cgit_snapshot_format *format, memset(&args, 0, sizeof(args)); + if (prefix) { args.base = fmt("%s/", prefix); + args.baselen = strlen(prefix) + 1; + } else { + args.base = ""; + args.baselen = 0; + } args.tree = commit->tree; |