static int cb_status__count(const char *GIT_UNUSED(p), unsigned int GIT_UNUSED(s), void *payload) { volatile int *count = (int *)payload; GIT_UNUSED_ARG(p); GIT_UNUSED_ARG(s); *count++; return GIT_SUCCESS; }
static int count_attrs( const char *GIT_UNUSED(name), const char *GIT_UNUSED(value), void *payload) { GIT_UNUSED_ARG(name); GIT_UNUSED_ARG(value); *((int *)payload) += 1; return GIT_SUCCESS; }
END_TEST static int status_cb1(const char *GIT_UNUSED(path), unsigned int GIT_UNUSED(status_flags), void *payload) { int *count = (int *)payload;; GIT_UNUSED_ARG(path); GIT_UNUSED_ARG(status_flags); (void) *count++; return GIT_SUCCESS; }
int main(int GIT_UNUSED(argc), char *GIT_UNUSED(argv[])) { unsigned int i, failures; GIT_UNUSED_ARG(argc); GIT_UNUSED_ARG(argv); p_umask(0); failures = 0; for (i = 0; i < GIT_SUITE_COUNT; ++i) failures += git_testsuite_run(suite_methods[i]()); return failures ? -1 : 0; }
/* * Try to open the url as a git directory. The direction doesn't * matter in this case because we're calulating the heads ourselves. */ static int local_connect(git_transport *transport, int GIT_UNUSED(direction)) { git_repository *repo; int error; transport_local *t = (transport_local *) transport; const char *path; const char file_prefix[] = "file://"; GIT_UNUSED_ARG(direction); /* The repo layer doesn't want the prefix */ if (!git__prefixcmp(transport->url, file_prefix)) path = transport->url + STRLEN(file_prefix); else path = transport->url; error = git_repository_open(&repo, path); if (error < GIT_SUCCESS) return git__rethrow(error, "Failed to open remote"); t->repo = repo; t->parent.connected = 1; return GIT_SUCCESS; }
GIT_INLINE(void) pack_window_free_all(struct pack_backend *GIT_UNUSED(backend), struct git_pack_file *p) { GIT_UNUSED_ARG(backend); git_mwindow_free_all(&p->mwf); }
int git_transport_dummy(git_transport **GIT_UNUSED(transport)) { GIT_UNUSED_ARG(transport); return git__throw(GIT_ENOTIMPLEMENTED, "This protocol isn't implemented. Sorry"); }
static int local_close(git_transport *GIT_UNUSED(transport)) { /* Nothing to do */ GIT_UNUSED_ARG(transport); return GIT_SUCCESS; }