diff options
author | Lars Hjemli | 2008-02-16 13:56:09 +0100 |
---|---|---|
committer | Lars Hjemli | 2008-02-16 13:56:09 +0100 |
commit | d1f3bbe9d22029f45a77bb938c176ccc0c827d46 (patch) | |
tree | 3f1741c012763cbc5485f31377abdd9241fbac6b /cgit.h | |
parent | b228d4ff82a65fdcd4a7364759fe36a0bdda5978 (diff) | |
download | cgit-d1f3bbe9d22029f45a77bb938c176ccc0c827d46.tar.gz cgit-d1f3bbe9d22029f45a77bb938c176ccc0c827d46.tar.bz2 cgit-d1f3bbe9d22029f45a77bb938c176ccc0c827d46.zip |
Move cgit_repo into cgit_context
This removes the global variable which is used to keep track of the
currently selected repository, and adds a new variable in the cgit_context
structure.
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
Diffstat (limited to 'cgit.h')
-rw-r--r-- | cgit.h | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -66,7 +66,7 @@ struct cacheitem { | |||
66 | int fd; | 66 | int fd; |
67 | }; | 67 | }; |
68 | 68 | ||
69 | struct repoinfo { | 69 | struct cgit_repo { |
70 | char *url; | 70 | char *url; |
71 | char *name; | 71 | char *name; |
72 | char *path; | 72 | char *path; |
@@ -82,10 +82,10 @@ struct repoinfo { | |||
82 | int enable_log_linecount; | 82 | int enable_log_linecount; |
83 | }; | 83 | }; |
84 | 84 | ||
85 | struct repolist { | 85 | struct cgit_repolist { |
86 | int length; | 86 | int length; |
87 | int count; | 87 | int count; |
88 | struct repoinfo *repos; | 88 | struct cgit_repo *repos; |
89 | }; | 89 | }; |
90 | 90 | ||
91 | struct commitinfo { | 91 | struct commitinfo { |
@@ -177,12 +177,12 @@ struct cgit_config { | |||
177 | struct cgit_context { | 177 | struct cgit_context { |
178 | struct cgit_query qry; | 178 | struct cgit_query qry; |
179 | struct cgit_config cfg; | 179 | struct cgit_config cfg; |
180 | struct cgit_repo *repo; | ||
180 | }; | 181 | }; |
181 | 182 | ||
182 | extern const char *cgit_version; | 183 | extern const char *cgit_version; |
183 | 184 | ||
184 | extern struct repolist cgit_repolist; | 185 | extern struct cgit_repolist cgit_repolist; |
185 | extern struct repoinfo *cgit_repo; | ||
186 | extern struct cgit_context ctx; | 186 | extern struct cgit_context ctx; |
187 | extern int cgit_cmd; | 187 | extern int cgit_cmd; |
188 | 188 | ||
@@ -190,7 +190,7 @@ extern int htmlfd; | |||
190 | 190 | ||
191 | extern void cgit_prepare_context(struct cgit_context *ctx); | 191 | extern void cgit_prepare_context(struct cgit_context *ctx); |
192 | extern int cgit_get_cmd_index(const char *cmd); | 192 | extern int cgit_get_cmd_index(const char *cmd); |
193 | extern struct repoinfo *cgit_get_repoinfo(const char *url); | 193 | extern struct cgit_repo *cgit_get_repoinfo(const char *url); |
194 | extern void cgit_global_config_cb(const char *name, const char *value); | 194 | extern void cgit_global_config_cb(const char *name, const char *value); |
195 | extern void cgit_repo_config_cb(const char *name, const char *value); | 195 | extern void cgit_repo_config_cb(const char *name, const char *value); |
196 | extern void cgit_querystring_cb(const char *name, const char *value); | 196 | extern void cgit_querystring_cb(const char *name, const char *value); |