| 325 | } |
| 326 | |
| 327 | static int |
| 328 | pygit2_refdb_backend_ensure_log(git_refdb_backend *_be, const char *refname) |
| 329 | { |
| 330 | int err; |
| 331 | PyObject *args, *result; |
| 332 | struct pygit2_refdb_backend *be = (struct pygit2_refdb_backend *)_be; |
| 333 | |
| 334 | if ((args = Py_BuildValue("(s)", refname)) == NULL) { |
| 335 | return GIT_EUSER; |
| 336 | } |
| 337 | result = PyObject_CallObject(be->ensure_log, args); |
| 338 | Py_DECREF(args); |
| 339 | |
| 340 | if ((err = git_error_for_exc()) != 0) { |
| 341 | return err; |
| 342 | } |
| 343 | |
| 344 | if (PyObject_IsTrue(result)) { |
| 345 | Py_DECREF(result); |
| 346 | return 1; |
| 347 | } |
| 348 | |
| 349 | Py_DECREF(result); |
| 350 | return 0; |
| 351 | } |
| 352 | |
| 353 | static int |
| 354 | pygit2_refdb_backend_reflog_read(git_reflog **out, |
nothing calls this directly
no test coverage detected
searching dependent graphs…