diff options
| -rw-r--r-- | ui-tree.c | 14 |
1 files changed, 8 insertions, 6 deletions
| @@ -73,12 +73,14 @@ static int ls_item(const unsigned char *sha1, const char *base, int baselen, | |||
| 73 | fullpath = fmt("%s%s%s", ctx.qry.path ? ctx.qry.path : "", | 73 | fullpath = fmt("%s%s%s", ctx.qry.path ? ctx.qry.path : "", |
| 74 | ctx.qry.path ? "/" : "", name); | 74 | ctx.qry.path ? "/" : "", name); |
| 75 | 75 | ||
| 76 | type = sha1_object_info(sha1, &size); | 76 | if (!S_ISGITLINK(mode)) { |
| 77 | if (type == OBJ_BAD && !S_ISGITLINK(mode)) { | 77 | type = sha1_object_info(sha1, &size); |
| 78 | htmlf("<tr><td colspan='3'>Bad object: %s %s</td></tr>", | 78 | if (type == OBJ_BAD) { |
| 79 | name, | 79 | htmlf("<tr><td colspan='3'>Bad object: %s %s</td></tr>", |
| 80 | sha1_to_hex(sha1)); | 80 | name, |
| 81 | return 0; | 81 | sha1_to_hex(sha1)); |
| 82 | return 0; | ||
| 83 | } | ||
| 82 | } | 84 | } |
| 83 | 85 | ||
| 84 | html("<tr><td class='ls-mode'>"); | 86 | html("<tr><td class='ls-mode'>"); |
