summaryrefslogtreecommitdiffabout
path: root/ui-blob.c
Unidiff
Diffstat (limited to 'ui-blob.c') (more/less context) (show whitespace changes)
-rw-r--r--ui-blob.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/ui-blob.c b/ui-blob.c
index f5b844b..be4fb88 100644
--- a/ui-blob.c
+++ b/ui-blob.c
@@ -1,13 +1,22 @@
1/* ui-blob.c: show blob content
2 *
3 * Copyright (C) 2008 Lars Hjemli
4 *
5 * Licensed under GNU General Public License v2
6 * (see COPYING for full license text)
7 */
8
1#include "cgit.h" 9#include "cgit.h"
10#include "html.h"
2 11
3void cgit_print_blob(struct cacheitem *item, const char *hex, char *path) 12void cgit_print_blob(struct cacheitem *item, const char *hex, char *path)
4{ 13{
5 14
6 unsigned char sha1[20]; 15 unsigned char sha1[20];
7 enum object_type type; 16 enum object_type type;
8 unsigned char *buf; 17 unsigned char *buf;
9 unsigned long size; 18 unsigned long size;
10 19
11 if (get_sha1_hex(hex, sha1)){ 20 if (get_sha1_hex(hex, sha1)){
12 cgit_print_error(fmt("Bad hex value: %s", hex)); 21 cgit_print_error(fmt("Bad hex value: %s", hex));
13 return; 22 return;