MCPcopy Create free account
hub / github.com/libgit2/pygit2 / OdbBackend_as_iter

Function OdbBackend_as_iter

src/odb_backend.c:320–340  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

318}
319
320PyObject *
321OdbBackend_as_iter(OdbBackend *self)
322{
323 PyObject *accum = PyList_New(0);
324 PyObject *iter = NULL;
325
326 int err = self->odb_backend->foreach(self->odb_backend, OdbBackend_build_as_iter, (void*)accum);
327 if (err == GIT_EUSER)
328 goto exit;
329
330 if (err < 0) {
331 Error_set(err);
332 goto exit;
333 }
334
335 iter = PyObject_GetIter(accum);
336
337exit:
338 Py_DECREF(accum);
339 return iter;
340}
341
342PyDoc_STRVAR(OdbBackend_read__doc__,
343 "read(oid) -> (type, data)\n"

Callers

nothing calls this directly

Calls 1

Error_setFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…