diff options
| author | Carlos Martín Nieto <[email protected]> | 2016-02-18 13:10:08 +0100 |
|---|---|---|
| committer | Carlos Martín Nieto <[email protected]> | 2016-02-18 13:10:08 +0100 |
| commit | f05417aaba1a6a01d9533c38b4901bfc58002f49 (patch) | |
| tree | 941f760c4a30200a0bfd0ce54cfd00e425aef8be /wrapper.c | |
| parent | 55594814c9009f9d645aea39a9f917cf82666228 (diff) | |
| parent | dc8b154f4f1b346fb6b8dee99fcfa6e4ca2d2d24 (diff) | |
Merge pull request #282 from ianlancetaylor/master
handles, merge, odb: changes for Go 1.6 pointer passing rules
Diffstat (limited to 'wrapper.c')
| -rw-r--r-- | wrapper.c | 23 |
1 files changed, 23 insertions, 0 deletions
@@ -141,4 +141,27 @@ int _go_git_tag_foreach(git_repository *repo, void *payload) return git_tag_foreach(repo, (git_tag_foreach_cb)&gitTagForeachCb, payload); } +int _go_git_merge_file(git_merge_file_result* out, char* ancestorContents, size_t ancestorLen, char* ancestorPath, unsigned int ancestorMode, char* oursContents, size_t oursLen, char* oursPath, unsigned int oursMode, char* theirsContents, size_t theirsLen, char* theirsPath, unsigned int theirsMode, git_merge_file_options* copts) { + git_merge_file_input ancestor = GIT_MERGE_FILE_INPUT_INIT; + git_merge_file_input ours = GIT_MERGE_FILE_INPUT_INIT; + git_merge_file_input theirs = GIT_MERGE_FILE_INPUT_INIT; + + ancestor.ptr = ancestorContents; + ancestor.size = ancestorLen; + ancestor.path = ancestorPath; + ancestor.mode = ancestorMode; + + ours.ptr = oursContents; + ours.size = oursLen; + ours.path = oursPath; + ours.mode = oursMode; + + theirs.ptr = theirsContents; + theirs.size = theirsLen; + theirs.path = theirsPath; + theirs.mode = theirsMode; + + return git_merge_file(out, &ancestor, &ours, &theirs, copts); +} + /* EOF */ |
