-rw-r--r-- | shared.c | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -30,2 +30,3 @@ char *cgit_query_head = NULL; char *cgit_query_sha1 = NULL; +int cgit_query_ofs = 0; @@ -61,7 +62,7 @@ void cgit_querystring_cb(const char *name, const char *value) { - if (!strcmp(name,"r")) + if (!strcmp(name,"r")) { cgit_query_repo = xstrdup(value); - else if (!strcmp(name, "p")) + } else if (!strcmp(name, "p")) { cgit_query_page = xstrdup(value); - else if (!strcmp(name, "h")) { + } else if (!strcmp(name, "h")) { cgit_query_head = xstrdup(value); @@ -71,2 +72,4 @@ void cgit_querystring_cb(const char *name, const char *value) cgit_query_has_sha1 = 1; + } else if (!strcmp(name, "ofs")) { + cgit_query_ofs = atoi(value); } |