|
diff --git a/shared.c b/shared.c index b576df8..762eb38 100644 --- a/ shared.c+++ b/ shared.c |
|
@@ -34,12 +34,13 @@ int cgit_query_has_sha1 = 0; |
34 | |
34 | |
35 | char *cgit_querystring = NULL; |
35 | char *cgit_querystring = NULL; |
36 | char *cgit_query_repo = NULL; |
36 | char *cgit_query_repo = NULL; |
37 | char *cgit_query_page = NULL; |
37 | char *cgit_query_page = NULL; |
38 | char *cgit_query_head = NULL; |
38 | char *cgit_query_head = NULL; |
39 | char *cgit_query_sha1 = NULL; |
39 | char *cgit_query_sha1 = NULL; |
| |
40 | char *cgit_query_sha2 = NULL; |
40 | int cgit_query_ofs = 0; |
41 | int cgit_query_ofs = 0; |
41 | |
42 | |
42 | int htmlfd = 0; |
43 | int htmlfd = 0; |
43 | |
44 | |
44 | void cgit_global_config_cb(const char *name, const char *value) |
45 | void cgit_global_config_cb(const char *name, const char *value) |
45 | { |
46 | { |
@@ -80,12 +81,15 @@ void cgit_querystring_cb(const char *name, const char *value) |
80 | } else if (!strcmp(name, "h")) { |
81 | } else if (!strcmp(name, "h")) { |
81 | cgit_query_head = xstrdup(value); |
82 | cgit_query_head = xstrdup(value); |
82 | cgit_query_has_symref = 1; |
83 | cgit_query_has_symref = 1; |
83 | } else if (!strcmp(name, "id")) { |
84 | } else if (!strcmp(name, "id")) { |
84 | cgit_query_sha1 = xstrdup(value); |
85 | cgit_query_sha1 = xstrdup(value); |
85 | cgit_query_has_sha1 = 1; |
86 | cgit_query_has_sha1 = 1; |
| |
87 | } else if (!strcmp(name, "id2")) { |
| |
88 | cgit_query_sha2 = xstrdup(value); |
| |
89 | cgit_query_has_sha1 = 1; |
86 | } else if (!strcmp(name, "ofs")) { |
90 | } else if (!strcmp(name, "ofs")) { |
87 | cgit_query_ofs = atoi(value); |
91 | cgit_query_ofs = atoi(value); |
88 | } |
92 | } |
89 | } |
93 | } |
90 | |
94 | |
91 | void *cgit_free_commitinfo(struct commitinfo *info) |
95 | void *cgit_free_commitinfo(struct commitinfo *info) |
|