From: Christian Couder Date: Wed, 03 Jan 2018 16:33:43 GMT Subject: [PATCH 20/40] external-odb: accept only blobs for now Message-ID: <20180103163403.11303-21-chriscool@tuxfamily.org> In-Reply-To: <20180103163403.11303-1-chriscool@tuxfamily.org> The mechanism to decide which blobs should be sent to which external object database will be very simple for now. If the external odb helper support any "put_*" instruction all the new blobs will be sent to it. Signed-off-by: Christian Couder --- external-odb.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/external-odb.c b/external-odb.c index 337bdd2540..93971e9ce4 100644 --- a/external-odb.c +++ b/external-odb.c @@ -159,6 +159,10 @@ int external_odb_put_object(const void *buf, size_t len, external_odb_init(); + /* For now accept only blobs */ + if (strcmp(type, "blob")) + return 1; + for (o = helpers; o; o = o->next) { int r = odb_helper_put_object(o, buf, len, type, sha1); if (r <= 0) -- 2.16.0.rc0.16.g82191dbc6c.dirty