aboutsummaryrefslogtreecommitdiff
path: root/shared.c
diff refs
from: back
to: back
| flip
diff options
context:
space:
mode:
Diffstat (limited to 'shared.c')
-rw-r--r--shared.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/shared.c b/shared.c
index 8beb7c7..83b5626 100644
--- a/shared.c
+++ b/shared.c
@@ -1,11 +1,6 @@
/* shared.c: global vars + some callback functions
*
* Copyright (C) 2006-2014 cgit Development Team <cgit@lists.zx2c4.com>
- * Copyright (C) 2026 Saya Andy <saya.andy@posteo.com>
- *
- * Modified 2026 by Saya Andy:
- * Add cgit_have_repository()
- * Add ci filter configuration
*
* Licensed under GNU General Public License v2
* (see COPYING for full license text)
@@ -18,6 +13,13 @@
struct cgit_repolist cgit_repolist;
struct cgit_context ctx;
+/* Returns true when the git repository belonging to this request was opened
+ * successfully. Some requests print a page for a repository which could not
+ * be opened, e.g. because repo.path is wrong, and the object database and
+ * ref stores must not be touched in that case: they would abort with
+ * "reference backend is unknown" or dereference the not yet known hash
+ * algorithm.
+ */
int cgit_have_repository(void)
{
return startup_info->have_repository;