shithub: git9

Download patch

ref: 5a6f8d7b9713f600f5029e21ece8117137f9ee12
parent: ab14718d835ffae7265db405b89ea29b216de8a8
author: Ori Bernstein <[email protected]>
date: Tue Aug 18 01:50:32 EDT 2020

don't garble tag objects

We still don't parse them -- but at least their contents are shown.

--- a/fs.c
+++ b/fs.c
@@ -621,9 +621,14 @@
 				return "invalid object name";
 			if((c->obj = readobject(h)) == nil)
 				return "could not read object";
-			c->mode = (c->obj->type == GBlob) ? 0644 : QTDIR | 0755;
+			if(c->obj->type == GBlob || c->obj->type == GTag){
+				c->mode = 0644;
+				q->type = 0;
+			}else{
+				c->mode = DMDIR | 0755;
+				q->type = QTDIR;
+			}
 			q->path = qpath(o, Qobject, c->obj->id, Qobject);
-			q->type = (c->obj->type == GBlob) ? 0 : QTDIR;
 			q->vers = 0;
 		}
 		break;