Perform a callback on each reference in the repository.
The callback function will be called for each reference in the
repository, receiving the reference object and the payload value
passed to this method. Returning a non-zero value from the callback
will terminate the iteration.
Note that the callback function is responsible to call git_reference_free
on each reference passed to it.
@param repo Repository where to find the refs
@param callback Function which will be called for every listed ref
@param payload Additional data to pass to the callback
@return 0 on success, non-zero callback return value, or error code
Perform a callback on each reference in the repository.
The callback function will be called for each reference in the repository, receiving the reference object and the payload value passed to this method. Returning a non-zero value from the callback will terminate the iteration.
Note that the callback function is responsible to call git_reference_free on each reference passed to it.
@param repo Repository where to find the refs @param callback Function which will be called for every listed ref @param payload Additional data to pass to the callback @return 0 on success, non-zero callback return value, or error code