summaryrefslogtreecommitdiff
path: root/wrapper.c
diff options
context:
space:
mode:
authorCarlos Martín Nieto <[email protected]>2017-01-20 22:55:25 +0000
committerGitHub <[email protected]>2017-01-20 22:55:25 +0000
commit4a14260153072e1e0d8e32d9270b30e3acca7c80 (patch)
tree112c3a1f75c2fcc8d3e88f1d0c6687de179e3ac3 /wrapper.c
parentb8a9efd21f5ea094976ff2c53c4aec1cf6014876 (diff)
parentb020c1140a2cb8be18141498a6cab5440409dc24 (diff)
Merge pull request #362 from libgit2/cmn/master-tip-static
Update master to latest libgit2 and build statically
Diffstat (limited to 'wrapper.c')
-rw-r--r--wrapper.c36
1 files changed, 23 insertions, 13 deletions
diff --git a/wrapper.c b/wrapper.c
index f4b4ecc..11c2f32 100644
--- a/wrapper.c
+++ b/wrapper.c
@@ -114,19 +114,6 @@ void _go_git_setup_callbacks(git_remote_callbacks *callbacks) {
callbacks->push_update_reference = (push_update_reference_cb) pushUpdateReferenceCallback;
}
-int _go_blob_chunk_cb(char *buffer, size_t maxLen, void *payload)
-{
- return blobChunkCb(buffer, maxLen, payload);
-}
-
-int _go_git_blob_create_fromchunks(git_oid *id,
- git_repository *repo,
- const char *hintpath,
- void *payload)
-{
- return git_blob_create_fromchunks(id, repo, hintpath, _go_blob_chunk_cb, payload);
-}
-
int _go_git_index_add_all(git_index *index, const git_strarray *pathspec, unsigned int flags, void *callback) {
git_index_matched_path_cb cb = callback ? (git_index_matched_path_cb) &indexMatchedPathCallback : NULL;
return git_index_add_all(index, pathspec, flags, cb, callback);
@@ -170,4 +157,27 @@ int _go_git_merge_file(git_merge_file_result* out, char* ancestorContents, size_
return git_merge_file(out, &ancestor, &ours, &theirs, copts);
}
+void _go_git_setup_stash_apply_progress_callbacks(git_stash_apply_options *opts) {
+ opts->progress_cb = (git_stash_apply_progress_cb)stashApplyProgressCb;
+}
+
+int _go_git_stash_foreach(git_repository *repo, void *payload) {
+ return git_stash_foreach(repo, (git_stash_cb)&stashForeachCb, payload);
+}
+
+int _go_git_writestream_write(git_writestream *stream, const char *buffer, size_t len)
+{
+ return stream->write(stream, buffer, len);
+}
+
+int _go_git_writestream_close(git_writestream *stream)
+{
+ return stream->close(stream);
+}
+
+void _go_git_writestream_free(git_writestream *stream)
+{
+ stream->free(stream);
+}
+
/* EOF */