mirror of
https://git.zx2c4.com/cgit
synced 2025-08-01 08:34:36 +02:00
Merge branch 'snapshot-fixes'
This commit is contained in:
commit
aa60ae12cb
2 changed files with 15 additions and 13 deletions
|
@ -175,10 +175,12 @@ void cgit_print_snapshot(const char *head, const char *hex,
|
|||
|
||||
if (!hex && dwim) {
|
||||
hex = get_ref_from_filename(ctx.repo->url, filename, f);
|
||||
if (hex != NULL) {
|
||||
prefix = xstrdup(filename);
|
||||
prefix[strlen(filename) - strlen(f->suffix)] = '\0';
|
||||
if (hex == NULL) {
|
||||
html_status(404, "Not found", 0);
|
||||
return;
|
||||
}
|
||||
prefix = xstrdup(filename);
|
||||
prefix[strlen(filename) - strlen(f->suffix)] = '\0';
|
||||
}
|
||||
|
||||
if (!hex)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue