| 155 | } |
| 156 | |
| 157 | static int |
| 158 | pgit_odb_backend_write(git_odb_backend *_be, const git_oid *oid, |
| 159 | const void *data, size_t sz, git_object_t typ) |
| 160 | { |
| 161 | pgit_odb_backend *be = (pgit_odb_backend *)_be; |
| 162 | |
| 163 | PyObject *py_oid = git_oid_to_python(oid); |
| 164 | if (py_oid == NULL) |
| 165 | return GIT_EUSER; |
| 166 | |
| 167 | PyObject *result = PyObject_CallMethod(be->py_backend, "write_cb", "Ny#n", py_oid, data, sz, typ); |
| 168 | if (result == NULL) |
| 169 | return git_error_for_exc(); |
| 170 | |
| 171 | Py_DECREF(result); |
| 172 | return 0; |
| 173 | } |
| 174 | |
| 175 | static int |
| 176 | pgit_odb_backend_exists(git_odb_backend *_be, const git_oid *oid) |
nothing calls this directly
no test coverage detected
searching dependent graphs…