diff options
author | Lars Hjemli | 2007-05-16 00:58:35 +0200 |
---|---|---|
committer | Lars Hjemli | 2007-05-16 00:58:35 +0200 |
commit | f9ff7df613b4ee86fe5914c4ae3400650882c03d (patch) | |
tree | c26fde3a4d3485943c275232f18359bebd133f1a /cgit.c | |
parent | a2ddc10479ec463708e422ca5ce7ec02c22a7d02 (diff) | |
download | cgit-f9ff7df613b4ee86fe5914c4ae3400650882c03d.tar.gz cgit-f9ff7df613b4ee86fe5914c4ae3400650882c03d.tar.bz2 cgit-f9ff7df613b4ee86fe5914c4ae3400650882c03d.zip |
Add support for commitdiff via h parameter
The commitdiff will be generated against the first parent, and the
diff page also gets the benefit of repo.defbranch.
Cleaned up some bad whitespace in cgit.h while at it.
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
Diffstat (limited to 'cgit.c')
-rw-r--r-- | cgit.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -120,7 +120,8 @@ static void cgit_print_repo_page(struct cacheitem *item) | |||
120 | } else if (!strcmp(cgit_query_page, "view")) { | 120 | } else if (!strcmp(cgit_query_page, "view")) { |
121 | cgit_print_view(cgit_query_sha1, cgit_query_path); | 121 | cgit_print_view(cgit_query_sha1, cgit_query_path); |
122 | } else if (!strcmp(cgit_query_page, "diff")) { | 122 | } else if (!strcmp(cgit_query_page, "diff")) { |
123 | cgit_print_diff(cgit_query_sha1, cgit_query_sha2, cgit_query_path); | 123 | cgit_print_diff(cgit_query_head, cgit_query_sha1, cgit_query_sha2, |
124 | cgit_query_path); | ||
124 | } else { | 125 | } else { |
125 | cgit_print_error("Invalid request"); | 126 | cgit_print_error("Invalid request"); |
126 | } | 127 | } |