| 218 | } |
| 219 | |
| 220 | static int |
| 221 | pgit_odb_backend_foreach(git_odb_backend *_be, |
| 222 | git_odb_foreach_cb cb, void *payload) |
| 223 | { |
| 224 | PyObject *item; |
| 225 | git_oid oid; |
| 226 | pgit_odb_backend *be = (pgit_odb_backend *)_be; |
| 227 | PyObject *iterator = PyObject_GetIter((PyObject *)be->py_backend); |
| 228 | assert(iterator); |
| 229 | |
| 230 | while ((item = PyIter_Next(iterator))) { |
| 231 | py_oid_to_git_oid(item, &oid); |
| 232 | cb(&oid, payload); |
| 233 | Py_DECREF(item); |
| 234 | } |
| 235 | |
| 236 | return git_error_for_exc(); |
| 237 | } |
| 238 | |
| 239 | static void |
| 240 | pgit_odb_backend_free(git_odb_backend *backend) |
nothing calls this directly
no test coverage detected
searching dependent graphs…