Commit Diff


commit - 48488136e0d5972cad38e3192ae5a615731bb97f
commit + 232c0ac1b26d38add9148b4e0382fc86c0cabd37
blob - de09563aef39f346f9cf2c078c8dff429dc7bc4a
blob + 0421be7b0d2bf6778bac2fb8bdeabcd60fc89ad2
--- gitwrapper/Makefile
+++ gitwrapper/Makefile
@@ -10,8 +10,7 @@ BINDIR ?=	${PREFIX}/bin
 PROG=		gitwrapper
 
 SRCS=		gitwrapper.c parse.y log.c dial.c path.c error.c \
-		reference_parse.c hash.c object_parse.c imsg.c \
-		inflate.c pollfd.c
+		reference_parse.c hash.c object_qid.c
 
 CLEANFILES = parse.h
 
blob - 6f68586c640662cd888e740dc5acaa83e889d438
blob + 61eb3c5d2c75ce1303a836e880c30e8394f98189
--- gotctl/Makefile
+++ gotctl/Makefile
@@ -3,7 +3,7 @@
 .include "../got-version.mk"
 
 PROG=		gotctl
-SRCS=		gotctl.c error.c imsg.c inflate.c object_parse.c path.c \
+SRCS=		gotctl.c error.c imsg.c object_qid.c path.c \
 		pollfd.c hash.c
 
 MAN =		${PROG}.8
blob - 3009e346a8d5ff1d82d8c7266688a122f425b807
blob + 57c307cbf240df2d50591814c9eb5e77bb24ae39
--- gotd/Makefile
+++ gotd/Makefile
@@ -15,7 +15,7 @@ SRCS=		gotd.c auth.c repo_read.c repo_write.c log.c pr
 		object_open_io.c object_parse.c opentemp.c pack.c path.c \
 		read_gitconfig.c read_gotconfig.c reference.c repository.c  \
 		hash.c sigs.c pack_create_io.c pollfd.c reference_parse.c \
-		repo_imsg.c pack_index.c session.c
+		repo_imsg.c pack_index.c session.c object_qid.c
 
 CLEANFILES = parse.h
 
blob - 764d96444519d4dfc13f888b5824e4c35e38e76f
blob + e181d09783d48cf8ca92d02f6f12aa9f0054a4f1
--- gotsh/Makefile
+++ gotsh/Makefile
@@ -4,8 +4,7 @@
 
 PROG=		gotsh
 SRCS=		gotsh.c error.c pkt.c hash.c serve.c path.c gitproto.c \
-		imsg.c inflate.c object_parse.c pollfd.c reference_parse.c \
-		dial.c
+		imsg.c pollfd.c dial.c reference_parse.c object_qid.c
 
 MAN =		${PROG}.1
 
blob - 05240d53214a844ee3d7b7d988783c9e4cfd7147
blob + 9daacd33712bbd6a9ded56d7a03ed143ce6642d3
--- gotwebd/libexec/got-read-blob/Makefile
+++ gotwebd/libexec/got-read-blob/Makefile
@@ -3,7 +3,7 @@
 
 PROG=		got-read-blob
 SRCS=		got-read-blob.c error.c inflate.c object_parse.c \
-		path.c privsep.c hash.c pollfd.c
+		path.c privsep.c hash.c pollfd.c object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../../include -I${.CURDIR}/../../../lib
 LDADD = -lutil -lz
blob - 1165c222b775505baa64d377371c136878c607c8
blob + f45137c3ce56dbaadeaf0a5f0ffffd3b4204668c
--- gotwebd/libexec/got-read-commit/Makefile
+++ gotwebd/libexec/got-read-commit/Makefile
@@ -3,7 +3,7 @@
 
 PROG=		got-read-commit
 SRCS=		got-read-commit.c error.c inflate.c object_parse.c \
-		path.c privsep.c hash.c pollfd.c
+		path.c privsep.c hash.c pollfd.c object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../../include -I${.CURDIR}/../../../lib
 LDADD = -lutil -lz
blob - e7bc462853862dcc5569354205b83cfa255442c1
blob + 44760613f030f1f1f62c831825d7bb85b07c9a46
--- gotwebd/libexec/got-read-gitconfig/Makefile
+++ gotwebd/libexec/got-read-gitconfig/Makefile
@@ -3,7 +3,8 @@
 
 PROG=		got-read-gitconfig
 SRCS=		got-read-gitconfig.c error.c inflate.c object_parse.c \
-		path.c privsep.c hash.c gitconfig.c pollfd.c
+		path.c privsep.c hash.c gitconfig.c pollfd.c \
+		object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../../include -I${.CURDIR}/../../../lib
 LDADD = -lutil -lz
blob - f148074e84910d2c34cba8f1bfe2985898b5d79a
blob + 26dec69ed1be0648baa16cabea96c54dc3731c54
--- gotwebd/libexec/got-read-gotconfig/Makefile
+++ gotwebd/libexec/got-read-gotconfig/Makefile
@@ -3,7 +3,7 @@
 
 PROG=		got-read-gotconfig
 SRCS=		got-read-gotconfig.c error.c inflate.c object_parse.c \
-		path.c privsep.c hash.c parse.y pollfd.c
+		path.c privsep.c hash.c parse.y pollfd.c object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../../include -I${.CURDIR}/../../../lib \
 	-I${.CURDIR}/../../../libexec/got-read-gotconfig
blob - 97907ead0bd33b477aa7c06d62d666b9c00564ab
blob + 85841212056443f99c873f1089e3fef315ab7d2a
--- gotwebd/libexec/got-read-object/Makefile
+++ gotwebd/libexec/got-read-object/Makefile
@@ -3,7 +3,7 @@
 
 PROG=		got-read-object
 SRCS=		got-read-object.c error.c inflate.c object_parse.c \
-		path.c privsep.c hash.c pollfd.c
+		path.c privsep.c hash.c pollfd.c object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../../include -I${.CURDIR}/../../../lib
 LDADD = -lutil -lz
blob - 12228b03188af547ebf7a86b8f434b966ed06b98
blob + 6ae7cd0c813fcc65f4256be6d06040df2d2880ba
--- gotwebd/libexec/got-read-pack/Makefile
+++ gotwebd/libexec/got-read-pack/Makefile
@@ -4,7 +4,7 @@
 PROG=		got-read-pack
 SRCS=		got-read-pack.c delta.c error.c inflate.c object_cache.c \
 		object_idset.c object_parse.c opentemp.c pack.c path.c \
-		privsep.c hash.c delta_cache.c pollfd.c
+		privsep.c hash.c delta_cache.c pollfd.c object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../../include -I${.CURDIR}/../../../lib
 LDADD = -lutil -lz
blob - e3695245b3e0161a86859b3cb3e10a413f4d74bb
blob + eb7b682a069470aa6b445adfc142e1d7bdf7c4a4
--- gotwebd/libexec/got-read-tag/Makefile
+++ gotwebd/libexec/got-read-tag/Makefile
@@ -3,7 +3,7 @@
 
 PROG=		got-read-tag
 SRCS=		got-read-tag.c error.c inflate.c object_parse.c \
-		path.c privsep.c hash.c pollfd.c
+		path.c privsep.c hash.c pollfd.c object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../../include -I${.CURDIR}/../../../lib
 LDADD = -lutil -lz
blob - db849065b699533903ca1e34443e2612c1983ec8
blob + 497d2ff1cd06d53bcc607653bb658219cd8ea982
--- gotwebd/libexec/got-read-tree/Makefile
+++ gotwebd/libexec/got-read-tree/Makefile
@@ -3,7 +3,7 @@
 
 PROG=		got-read-tree
 SRCS=		got-read-tree.c error.c inflate.c object_parse.c \
-		path.c privsep.c hash.c pollfd.c
+		path.c privsep.c hash.c pollfd.c object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../../include -I${.CURDIR}/../../../lib
 LDADD = -lutil -lz
blob - f02cebec77dbb2e815b7375242abbcc7c7d970bf
blob + 4e6234fa5cd6f8448921a97529adc9749d61dde7
--- lib/error.c
+++ lib/error.c
@@ -32,6 +32,7 @@
 #include "got_lib_delta.h"
 #include "got_lib_inflate.h"
 #include "got_lib_object.h"
+#include "got_lib_hash.h"
 #include "got_lib_object_parse.h"
 
 #ifndef nitems
blob - 1405a67ac335af59f8e1c2f04ac566ecd07436e7
blob + 88c77f6eb9da4d589aefd2ed3e9539327d379e53
--- lib/got_lib_hash.h
+++ lib/got_lib_hash.h
@@ -25,6 +25,14 @@ char *got_sha1_digest_to_str(const uint8_t *, char *, 
 char *got_sha256_digest_to_str(const uint8_t *, char *, size_t);
 
 int got_parse_hash_digest(uint8_t *, const char *, enum got_hash_algorithm);
+
+/*
+ * Write the string representation fo an object ID in the given buffer.
+ * This buffer must be at least GOT_OBJECT_ID_HEX_MAXLEN bytes in size.
+ * The output depneds on the hash function used by the repository format.
+ */
+char *got_object_id_hex(struct got_object_id *, char *, size_t);
+
 int got_parse_object_id(struct got_object_id *, const char *,
     enum got_hash_algorithm);
 
blob - 767c404755f278059ea3f7b3890ee3a3d0188974
blob + e0d04d5ded1ba4a6804afe49bf9df83eda5d2250
--- lib/got_lib_object_parse.h
+++ lib/got_lib_object_parse.h
@@ -16,16 +16,8 @@
 
 struct got_pathlist_head;
 
-/*
- * Write the string representation fo an object ID in the given buffer.
- * This buffer must be at least GOT_OBJECT_ID_HEX_MAXLEN bytes in size.
- * The output depneds on the hash function used by the repository format.
- */
-char *got_object_id_hex(struct got_object_id *, char *, size_t);
-
 const struct got_error *got_object_type_label(const char **, int);
 
-const struct got_error *got_object_qid_alloc_partial(struct got_object_qid **);
 struct got_commit_object *got_object_commit_alloc_partial(void);
 struct got_tree_entry *got_alloc_tree_entry_partial(void);
 
blob - /dev/null
blob + 3da5974aee776a379af798d1bc6dcf8f93085579 (mode 644)
--- /dev/null
+++ lib/got_lib_object_qid.h
@@ -0,0 +1,17 @@
+/*
+ * Copyright (c) 2018, 2019, 2020, 2023 Stefan Sperling <stsp@openbsd.org>
+ *
+ * Permission to use, copy, modify, and distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ */
+
+const struct got_error *got_object_qid_alloc_partial(struct got_object_qid **);
blob - 72130751b2d228dbd5ee224857661dc3217d263f
blob + 641d2b5b84fd5163c607e96980ad52cb3109c1ae
--- lib/hash.c
+++ lib/hash.c
@@ -26,10 +26,48 @@
 #include <limits.h>
 
 #include "got_object.h"
+#include "got_error.h"
 
 #include "got_lib_hash.h"
 
+struct got_object_id *
+got_object_id_dup(struct got_object_id *id1)
+{
+	struct got_object_id *id2;
+
+	id2 = malloc(sizeof(*id2));
+	if (id2 == NULL)
+		return NULL;
+	memcpy(id2, id1, sizeof(*id2));
+	return id2;
+}
+
 int
+got_object_id_cmp(const struct got_object_id *id1,
+    const struct got_object_id *id2)
+{
+	return memcmp(id1->sha1, id2->sha1, SHA1_DIGEST_LENGTH);
+}
+
+const struct got_error *
+got_object_id_str(char **outbuf, struct got_object_id *id)
+{
+	static const size_t len = GOT_OBJECT_ID_HEX_MAXLEN;
+
+	*outbuf = malloc(len);
+	if (*outbuf == NULL)
+		return got_error_from_errno("malloc");
+
+	if (got_object_id_hex(id, *outbuf, len) == NULL) {
+		free(*outbuf);
+		*outbuf = NULL;
+		return got_error(GOT_ERR_BAD_OBJ_ID_STR);
+	}
+
+	return NULL;
+}
+
+int
 got_parse_xdigit(uint8_t *val, const char *hex)
 {
 	char *ep;
@@ -114,6 +152,12 @@ got_parse_hash_digest(uint8_t *digest, const char *lin
 	}
 }
 
+char *
+got_object_id_hex(struct got_object_id *id, char *buf, size_t len)
+{
+	return got_sha1_digest_to_str(id->sha1, buf, len);
+}
+
 int
 got_parse_object_id(struct got_object_id *id, const char *line,
     enum got_hash_algorithm algo)
blob - 45999e4f415da86af0a70702f0cd75bd530205e8
blob + c8f77ee93a078ac6e44faf47dced3ce65da6c463
--- lib/object.c
+++ lib/object.c
@@ -175,41 +175,6 @@ got_object_resolve_id_str(struct got_object_id **id,
 	return NULL;
 }
 
-const struct got_error *
-got_object_qid_alloc(struct got_object_qid **qid, struct got_object_id *id)
-{
-	*qid = calloc(1, sizeof(**qid));
-	if (*qid == NULL)
-		return got_error_from_errno("calloc");
-
-	memcpy(&(*qid)->id, id, sizeof((*qid)->id));
-	return NULL;
-}
-
-const struct got_error *
-got_object_id_queue_copy(const struct got_object_id_queue *src,
-    struct got_object_id_queue *dest)
-{
-	const struct got_error *err;
-	struct got_object_qid *qid;
-
-	STAILQ_FOREACH(qid, src, entry) {
-		struct got_object_qid *new;
-		/*
-		 * Deep-copy the object ID only. Let the caller deal
-		 * with setting up the new->data pointer if needed.
-		 */
-		err = got_object_qid_alloc(&new, &qid->id);
-		if (err) {
-			got_object_id_queue_free(dest);
-			return err;
-		}
-		STAILQ_INSERT_TAIL(dest, new, entry);
-	}
-
-	return NULL;
-}
-
 int
 got_object_tree_get_nentries(struct got_tree_object *tree)
 {
blob - dc9175ad60883e788dd8423ab2847d17d17539ce
blob + 37547ec04aef0ab91edd82c764c5f166d94c0f0b
--- lib/object_idset.c
+++ lib/object_idset.c
@@ -32,6 +32,7 @@
 #include "got_lib_delta.h"
 #include "got_lib_inflate.h"
 #include "got_lib_object.h"
+#include "got_lib_object_qid.h"
 #include "got_lib_object_idset.h"
 #include "got_lib_object_parse.h"
 
blob - c0b1855c518c2630ff4a38ada9e593cbd10c74bd
blob + e16496ab684e9fb134c63bfecd30b8dac21971ca
--- lib/object_parse.c
+++ lib/object_parse.c
@@ -46,6 +46,7 @@
 #include "got_lib_inflate.h"
 #include "got_lib_object.h"
 #include "got_lib_object_parse.h"
+#include "got_lib_object_qid.h"
 #include "got_lib_object_cache.h"
 #include "got_lib_pack.h"
 #include "got_lib_repository.h"
@@ -54,61 +55,7 @@
 #define nitems(_a) (sizeof(_a) / sizeof((_a)[0]))
 #endif
 
-struct got_object_id *
-got_object_id_dup(struct got_object_id *id1)
-{
-	struct got_object_id *id2;
-
-	id2 = malloc(sizeof(*id2));
-	if (id2 == NULL)
-		return NULL;
-	memcpy(id2, id1, sizeof(*id2));
-	return id2;
-}
-
-int
-got_object_id_cmp(const struct got_object_id *id1,
-    const struct got_object_id *id2)
-{
-	return memcmp(id1->sha1, id2->sha1, SHA1_DIGEST_LENGTH);
-}
-
 const struct got_error *
-got_object_qid_alloc_partial(struct got_object_qid **qid)
-{
-	*qid = malloc(sizeof(**qid));
-	if (*qid == NULL)
-		return got_error_from_errno("malloc");
-
-	(*qid)->data = NULL;
-	return NULL;
-}
-
-const struct got_error *
-got_object_id_str(char **outbuf, struct got_object_id *id)
-{
-	static const size_t len = GOT_OBJECT_ID_HEX_MAXLEN;
-
-	*outbuf = malloc(len);
-	if (*outbuf == NULL)
-		return got_error_from_errno("malloc");
-
-	if (got_object_id_hex(id, *outbuf, len) == NULL) {
-		free(*outbuf);
-		*outbuf = NULL;
-		return got_error(GOT_ERR_BAD_OBJ_ID_STR);
-	}
-
-	return NULL;
-}
-
-char *
-got_object_id_hex(struct got_object_id *id, char *buf, size_t len)
-{
-	return got_sha1_digest_to_str(id->sha1, buf, len);
-}
-
-const struct got_error *
 got_object_type_label(const char **label, int obj_type)
 {
 	const struct got_error *err = NULL;
@@ -183,24 +130,6 @@ got_object_raw_close(struct got_raw_object *obj)
 	}
 	free(obj);
 	return err;
-}
-
-void
-got_object_qid_free(struct got_object_qid *qid)
-{
-	free(qid);
-}
-
-void
-got_object_id_queue_free(struct got_object_id_queue *ids)
-{
-	struct got_object_qid *qid;
-
-	while (!STAILQ_EMPTY(ids)) {
-		qid = STAILQ_FIRST(ids);
-		STAILQ_REMOVE_HEAD(ids, entry);
-		got_object_qid_free(qid);
-	}
 }
 
 const struct got_error *
blob - fa0205ad0837ff160574fa8c81b6ba5f581c334f
blob + 2b3827d2bd6033b3a694f474b6d68ae211330bae
--- lib/pack.c
+++ lib/pack.c
@@ -42,6 +42,7 @@
 #include "got_lib_delta_cache.h"
 #include "got_lib_inflate.h"
 #include "got_lib_object.h"
+#include "got_lib_object_qid.h"
 #include "got_lib_object_parse.h"
 #include "got_lib_privsep.h"
 #include "got_lib_pack.h"
blob - /dev/null
blob + e4574472a88375bfac44ed049b2e5050ad77a389 (mode 644)
--- /dev/null
+++ lib/object_qid.c
@@ -0,0 +1,93 @@
+/*
+ * Copyright (c) 2018, 2019, 2020, 2023 Stefan Sperling <stsp@openbsd.org>
+ *
+ * Permission to use, copy, modify, and distribute this software for any
+ * purpose with or without fee is hereby granted, provided that the above
+ * copyright notice and this permission notice appear in all copies.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+ */
+
+#include <sys/queue.h>
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <sha1.h>
+#include <sha2.h>
+
+#include "got_object.h"
+#include "got_error.h"
+
+#include "got_lib_object_qid.h"
+#include "got_lib_hash.h"
+
+const struct got_error *
+got_object_qid_alloc_partial(struct got_object_qid **qid)
+{
+	*qid = malloc(sizeof(**qid));
+	if (*qid == NULL)
+		return got_error_from_errno("malloc");
+
+	(*qid)->data = NULL;
+	return NULL;
+}
+
+const struct got_error *
+got_object_qid_alloc(struct got_object_qid **qid, struct got_object_id *id)
+{
+	*qid = calloc(1, sizeof(**qid));
+	if (*qid == NULL)
+		return got_error_from_errno("calloc");
+
+	memcpy(&(*qid)->id, id, sizeof((*qid)->id));
+	return NULL;
+}
+
+void
+got_object_qid_free(struct got_object_qid *qid)
+{
+	free(qid);
+}
+
+void
+got_object_id_queue_free(struct got_object_id_queue *ids)
+{
+	struct got_object_qid *qid;
+
+	while (!STAILQ_EMPTY(ids)) {
+		qid = STAILQ_FIRST(ids);
+		STAILQ_REMOVE_HEAD(ids, entry);
+		got_object_qid_free(qid);
+	}
+}
+
+const struct got_error *
+got_object_id_queue_copy(const struct got_object_id_queue *src,
+    struct got_object_id_queue *dest)
+{
+	const struct got_error *err;
+	struct got_object_qid *qid;
+
+	STAILQ_FOREACH(qid, src, entry) {
+		struct got_object_qid *new;
+		/*
+		 * Deep-copy the object ID only. Let the caller deal
+		 * with setting up the new->data pointer if needed.
+		 */
+		err = got_object_qid_alloc(&new, &qid->id);
+		if (err) {
+			got_object_id_queue_free(dest);
+			return err;
+		}
+		STAILQ_INSERT_TAIL(dest, new, entry);
+	}
+
+	return NULL;
+}
blob - 57c7e0e532d44492699622e9ff0ff3feab6aee72
blob + d56e19fc2744b0f22deaf1ece97b29a917c4747d
--- lib/privsep.c
+++ lib/privsep.c
@@ -45,6 +45,7 @@
 #include "got_lib_inflate.h"
 #include "got_lib_object.h"
 #include "got_lib_object_parse.h"
+#include "got_lib_object_qid.h"
 #include "got_lib_privsep.h"
 #include "got_lib_pack.h"
 #include "got_lib_poll.h"
blob - f2bf2185dc27d0f3e9af94ce9669b99b2a0f2c82
blob + 85c7a6b22b87d00ea63811681448ccb592e87830
--- libexec/got-index-pack/got-index-pack.c
+++ libexec/got-index-pack/got-index-pack.c
@@ -37,6 +37,7 @@
 #include "got_lib_delta_cache.h"
 #include "got_lib_hash.h"
 #include "got_lib_object.h"
+#include "got_lib_object_qid.h"
 #include "got_lib_privsep.h"
 #include "got_lib_ratelimit.h"
 #include "got_lib_pack.h"
blob - 1a2bbf0db3a492eb7b95f7e964508cdc0c505f2d
blob + cdd1a966e34a11d85d27e9e65b280de9e8c735b7
--- libexec/got-read-commit/got-read-commit.c
+++ libexec/got-read-commit/got-read-commit.c
@@ -37,6 +37,7 @@
 #include "got_lib_inflate.h"
 #include "got_lib_object.h"
 #include "got_lib_object_parse.h"
+#include "got_lib_object_qid.h"
 #include "got_lib_privsep.h"
 #include "got_lib_hash.h"
 
blob - da45705204927e59fcf0cd17efc003bdd2b91ac6
blob + 8bedfc6195a0071889774c278c4b9a67e9479a41
--- libexec/got-read-pack/got-read-pack.c
+++ libexec/got-read-pack/got-read-pack.c
@@ -39,6 +39,7 @@
 #include "got_lib_delta.h"
 #include "got_lib_delta_cache.h"
 #include "got_lib_object.h"
+#include "got_lib_object_qid.h"
 #include "got_lib_object_cache.h"
 #include "got_lib_object_parse.h"
 #include "got_lib_object_idset.h"
blob - 475dd4289d617e4ccfde05e7dd965aadacae6aff
blob + 45aa930f4a42d5bb431534bef25ce8c8b73c2944
--- regress/delta/Makefile
+++ regress/delta/Makefile
@@ -2,7 +2,7 @@
 
 PROG = delta_test
 SRCS = delta.c error.c opentemp.c path.c inflate.c hash.c delta_test.c \
-	pollfd.c object_parse.c
+	pollfd.c object_parse.c object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../include -I${.CURDIR}/../../lib
 LDADD = -lz
blob - c89d76ee9c4539c7d7c3907089ab2b233a8744a2
blob + f842e2c2c6f4297790ef648c442b81054653f1cb
--- regress/deltify/Makefile
+++ regress/deltify/Makefile
@@ -2,7 +2,7 @@
 
 PROG = deltify_test
 SRCS = deltify.c error.c opentemp.c hash.c deltify_test.c murmurhash2.c \
-	object_parse.c inflate.c path.c pollfd.c
+	object_parse.c inflate.c path.c pollfd.c object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../include -I${.CURDIR}/../../lib
 LDADD = -lz
blob - 4c3c7abb0a9b0de487050e9bc9149cb0d46f9749
blob + 5226e9385a97d432d2d5b872248237c615ba1f26
--- regress/fetch/Makefile
+++ regress/fetch/Makefile
@@ -6,7 +6,7 @@ SRCS = error.c privsep.c reference.c hash.c object.c o
 	deflate.c delta.c delta_cache.c object_idset.c object_create.c \
 	fetch.c gotconfig.c dial.c fetch_test.c bloom.c murmurhash2.c sigs.c \
 	buf.c date.c object_open_privsep.c read_gitconfig_privsep.c \
-	read_gotconfig_privsep.c pollfd.c reference_parse.c
+	read_gotconfig_privsep.c pollfd.c reference_parse.c object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../include -I${.CURDIR}/../../lib
 LDADD = -lutil -lz -lm
blob - 6b78a4717b9682af0793283e080f4458ab6a8b8e
blob + 57a49d224d6446e0fd67a0b5e72a31608b40be31
--- regress/idset/Makefile
+++ regress/idset/Makefile
@@ -2,7 +2,7 @@
 
 PROG = idset_test
 SRCS = error.c hash.c object_idset.c inflate.c path.c object_parse.c \
-	idset_test.c pollfd.c
+	idset_test.c pollfd.c object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../include -I${.CURDIR}/../../lib
 LDADD = -lutil -lz
blob - 23a916db855dd46d0844a60ae1b609c2e9c37279
blob + 54b4f76a6f8bc2e2a14de909de4e7aced350c5d9
--- regress/path/Makefile
+++ regress/path/Makefile
@@ -1,7 +1,8 @@
 .PATH:${.CURDIR}/../../lib
 
 PROG = path_test
-SRCS = error.c path.c hash.c path_test.c object_parse.c inflate.c pollfd.c
+SRCS = error.c path.c hash.c path_test.c object_parse.c inflate.c pollfd.c \
+	object_qid.c
 
 CPPFLAGS = -I${.CURDIR}/../../include -I${.CURDIR}/../../lib
 LDADD = -lutil -lz