rugged 1.1.1 → 1.4.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE +1 -0
- data/README.md +1 -1
- data/ext/rugged/extconf.rb +2 -2
- data/ext/rugged/rugged.c +7 -4
- data/ext/rugged/rugged_config.c +7 -2
- data/ext/rugged/rugged_object.c +1 -1
- data/ext/rugged/rugged_remote.c +17 -0
- data/ext/rugged/rugged_repo.c +3 -3
- data/lib/rugged/repository.rb +2 -2
- data/lib/rugged/version.rb +1 -1
- data/vendor/libgit2/CMakeLists.txt +103 -271
- data/vendor/libgit2/COPYING +149 -24
- data/vendor/libgit2/cmake/AddCFlagIfSupported.cmake +21 -21
- data/vendor/libgit2/cmake/DefaultCFlags.cmake +154 -0
- data/vendor/libgit2/cmake/EnableWarnings.cmake +13 -13
- data/vendor/libgit2/cmake/FindCoreFoundation.cmake +13 -13
- data/vendor/libgit2/cmake/FindGSSAPI.cmake +171 -287
- data/vendor/libgit2/cmake/FindGSSFramework.cmake +13 -13
- data/vendor/libgit2/cmake/{FindHTTP_Parser.cmake → FindHTTPParser.cmake} +17 -17
- data/vendor/libgit2/cmake/FindIconv.cmake +27 -27
- data/vendor/libgit2/cmake/FindLibSSH2.cmake +13 -0
- data/vendor/libgit2/cmake/FindPCRE.cmake +13 -13
- data/vendor/libgit2/cmake/FindPCRE2.cmake +12 -12
- data/vendor/libgit2/cmake/FindPkgLibraries.cmake +19 -19
- data/vendor/libgit2/cmake/FindSecurity.cmake +14 -14
- data/vendor/libgit2/cmake/FindStatNsec.cmake +12 -18
- data/vendor/libgit2/cmake/Findfutimens.cmake +14 -0
- data/vendor/libgit2/cmake/FindmbedTLS.cmake +63 -70
- data/vendor/libgit2/cmake/IdeSplitSources.cmake +18 -18
- data/vendor/libgit2/cmake/PkgBuildConfig.cmake +60 -60
- data/vendor/libgit2/cmake/SanitizeBool.cmake +20 -20
- data/vendor/libgit2/cmake/SelectGSSAPI.cmake +37 -37
- data/vendor/libgit2/cmake/SelectHTTPParser.cmake +19 -0
- data/vendor/libgit2/cmake/SelectHTTPSBackend.cmake +100 -96
- data/vendor/libgit2/cmake/SelectHashes.cmake +39 -48
- data/vendor/libgit2/cmake/SelectRegex.cmake +51 -0
- data/vendor/libgit2/cmake/SelectSSH.cmake +41 -0
- data/vendor/libgit2/cmake/SelectWinHTTP.cmake +17 -0
- data/vendor/libgit2/cmake/SelectZlib.cmake +34 -0
- data/vendor/libgit2/deps/chromium-zlib/CMakeLists.txt +101 -0
- data/vendor/libgit2/deps/ntlmclient/CMakeLists.txt +32 -20
- data/vendor/libgit2/deps/ntlmclient/crypt.h +14 -9
- data/vendor/libgit2/deps/ntlmclient/crypt_commoncrypto.c +20 -20
- data/vendor/libgit2/deps/ntlmclient/crypt_commoncrypto.h +3 -3
- data/vendor/libgit2/deps/ntlmclient/crypt_mbedtls.c +37 -36
- data/vendor/libgit2/deps/ntlmclient/crypt_mbedtls.h +4 -3
- data/vendor/libgit2/deps/ntlmclient/crypt_openssl.c +178 -51
- data/vendor/libgit2/deps/ntlmclient/crypt_openssl.h +74 -5
- data/vendor/libgit2/deps/ntlmclient/ntlm.c +154 -122
- data/vendor/libgit2/deps/ntlmclient/ntlm.h +17 -13
- data/vendor/libgit2/deps/ntlmclient/ntlmclient.h +17 -4
- data/vendor/libgit2/deps/ntlmclient/unicode.h +10 -4
- data/vendor/libgit2/deps/ntlmclient/unicode_builtin.c +16 -27
- data/vendor/libgit2/deps/ntlmclient/unicode_builtin.h +20 -0
- data/vendor/libgit2/deps/ntlmclient/unicode_iconv.c +28 -52
- data/vendor/libgit2/deps/ntlmclient/unicode_iconv.h +22 -0
- data/vendor/libgit2/deps/pcre/CMakeLists.txt +88 -88
- data/vendor/libgit2/deps/winhttp/CMakeLists.txt +14 -16
- data/vendor/libgit2/include/git2/apply.h +16 -2
- data/vendor/libgit2/include/git2/attr.h +106 -2
- data/vendor/libgit2/include/git2/blame.h +97 -43
- data/vendor/libgit2/include/git2/blob.h +33 -2
- data/vendor/libgit2/include/git2/branch.h +27 -0
- data/vendor/libgit2/include/git2/buffer.h +18 -78
- data/vendor/libgit2/include/git2/cert.h +43 -6
- data/vendor/libgit2/include/git2/checkout.h +32 -13
- data/vendor/libgit2/include/git2/clone.h +4 -4
- data/vendor/libgit2/include/git2/commit.h +37 -19
- data/vendor/libgit2/include/git2/common.h +46 -5
- data/vendor/libgit2/include/git2/config.h +19 -3
- data/vendor/libgit2/include/git2/credential.h +2 -1
- data/vendor/libgit2/include/git2/credential_helpers.h +1 -0
- data/vendor/libgit2/include/git2/deprecated.h +326 -6
- data/vendor/libgit2/include/git2/describe.h +7 -2
- data/vendor/libgit2/include/git2/diff.h +50 -121
- data/vendor/libgit2/include/git2/email.h +127 -0
- data/vendor/libgit2/include/git2/errors.h +7 -6
- data/vendor/libgit2/include/git2/filter.h +69 -18
- data/vendor/libgit2/include/git2/graph.h +21 -2
- data/vendor/libgit2/include/git2/ignore.h +1 -1
- data/vendor/libgit2/include/git2/index.h +13 -7
- data/vendor/libgit2/include/git2/indexer.h +19 -0
- data/vendor/libgit2/include/git2/merge.h +23 -3
- data/vendor/libgit2/include/git2/message.h +2 -0
- data/vendor/libgit2/include/git2/notes.h +2 -2
- data/vendor/libgit2/include/git2/object.h +23 -0
- data/vendor/libgit2/include/git2/odb.h +65 -6
- data/vendor/libgit2/include/git2/odb_backend.h +1 -1
- data/vendor/libgit2/include/git2/oidarray.h +5 -8
- data/vendor/libgit2/include/git2/pack.h +24 -8
- data/vendor/libgit2/include/git2/patch.h +16 -0
- data/vendor/libgit2/include/git2/pathspec.h +1 -1
- data/vendor/libgit2/include/git2/proxy.h +1 -1
- data/vendor/libgit2/include/git2/rebase.h +34 -2
- data/vendor/libgit2/include/git2/refdb.h +3 -0
- data/vendor/libgit2/include/git2/reflog.h +1 -1
- data/vendor/libgit2/include/git2/refs.h +8 -4
- data/vendor/libgit2/include/git2/remote.h +246 -46
- data/vendor/libgit2/include/git2/repository.h +25 -18
- data/vendor/libgit2/include/git2/reset.h +2 -2
- data/vendor/libgit2/include/git2/revparse.h +5 -5
- data/vendor/libgit2/include/git2/revwalk.h +4 -1
- data/vendor/libgit2/include/git2/signature.h +1 -1
- data/vendor/libgit2/include/git2/stash.h +4 -4
- data/vendor/libgit2/include/git2/status.h +124 -62
- data/vendor/libgit2/include/git2/stdint.h +3 -3
- data/vendor/libgit2/include/git2/submodule.h +16 -2
- data/vendor/libgit2/include/git2/sys/commit_graph.h +174 -0
- data/vendor/libgit2/include/git2/sys/email.h +45 -0
- data/vendor/libgit2/include/git2/sys/filter.h +49 -28
- data/vendor/libgit2/include/git2/sys/midx.h +74 -0
- data/vendor/libgit2/include/git2/sys/odb_backend.h +9 -5
- data/vendor/libgit2/include/git2/sys/remote.h +31 -0
- data/vendor/libgit2/include/git2/sys/stream.h +1 -1
- data/vendor/libgit2/include/git2/sys/transport.h +26 -34
- data/vendor/libgit2/include/git2/tag.h +13 -0
- data/vendor/libgit2/include/git2/tree.h +4 -17
- data/vendor/libgit2/include/git2/types.h +16 -7
- data/vendor/libgit2/include/git2/version.h +4 -4
- data/vendor/libgit2/include/git2/worktree.h +13 -2
- data/vendor/libgit2/include/git2.h +1 -0
- data/vendor/libgit2/src/CMakeLists.txt +192 -290
- data/vendor/libgit2/src/alloc.c +21 -8
- data/vendor/libgit2/src/allocators/failalloc.c +92 -0
- data/vendor/libgit2/src/allocators/failalloc.h +23 -0
- data/vendor/libgit2/src/allocators/stdalloc.c +41 -10
- data/vendor/libgit2/src/allocators/win32_leakcheck.c +118 -0
- data/vendor/libgit2/src/allocators/{win32_crtdbg.h → win32_leakcheck.h} +3 -3
- data/vendor/libgit2/src/annotated_commit.c +21 -9
- data/vendor/libgit2/src/annotated_commit.h +1 -1
- data/vendor/libgit2/src/apply.c +34 -25
- data/vendor/libgit2/src/apply.h +2 -2
- data/vendor/libgit2/src/array.h +11 -11
- data/vendor/libgit2/src/attr.c +204 -82
- data/vendor/libgit2/src/attr_file.c +105 -52
- data/vendor/libgit2/src/attr_file.h +36 -15
- data/vendor/libgit2/src/attrcache.c +55 -45
- data/vendor/libgit2/src/attrcache.h +4 -5
- data/vendor/libgit2/src/blame.c +15 -9
- data/vendor/libgit2/src/blame_git.c +2 -2
- data/vendor/libgit2/src/blob.c +76 -52
- data/vendor/libgit2/src/blob.h +1 -1
- data/vendor/libgit2/src/branch.c +203 -110
- data/vendor/libgit2/src/branch.h +15 -3
- data/vendor/libgit2/src/buf.c +126 -0
- data/vendor/libgit2/src/buf.h +50 -0
- data/vendor/libgit2/src/cache.c +2 -2
- data/vendor/libgit2/src/cache.h +7 -7
- data/vendor/libgit2/src/cc-compat.h +11 -9
- data/vendor/libgit2/src/checkout.c +118 -91
- data/vendor/libgit2/src/cherrypick.c +16 -12
- data/vendor/libgit2/src/clone.c +97 -103
- data/vendor/libgit2/src/commit.c +167 -84
- data/vendor/libgit2/src/commit.h +24 -1
- data/vendor/libgit2/src/commit_graph.c +1224 -0
- data/vendor/libgit2/src/commit_graph.h +169 -0
- data/vendor/libgit2/src/commit_list.c +48 -3
- data/vendor/libgit2/src/commit_list.h +2 -0
- data/vendor/libgit2/src/common.h +35 -5
- data/vendor/libgit2/src/config.c +119 -64
- data/vendor/libgit2/src/config.h +15 -2
- data/vendor/libgit2/src/config_cache.c +5 -3
- data/vendor/libgit2/src/config_file.c +120 -100
- data/vendor/libgit2/src/config_mem.c +9 -9
- data/vendor/libgit2/src/config_parse.c +29 -27
- data/vendor/libgit2/src/crlf.c +36 -23
- data/vendor/libgit2/src/date.c +13 -19
- data/vendor/libgit2/src/date.h +33 -0
- data/vendor/libgit2/src/delta.c +1 -1
- data/vendor/libgit2/src/describe.c +32 -21
- data/vendor/libgit2/src/diff.c +71 -183
- data/vendor/libgit2/src/diff.h +2 -4
- data/vendor/libgit2/src/diff_driver.c +53 -51
- data/vendor/libgit2/src/diff_driver.h +3 -3
- data/vendor/libgit2/src/diff_file.c +31 -26
- data/vendor/libgit2/src/diff_generate.c +76 -23
- data/vendor/libgit2/src/diff_generate.h +5 -3
- data/vendor/libgit2/src/diff_print.c +120 -95
- data/vendor/libgit2/src/diff_stats.c +47 -34
- data/vendor/libgit2/src/{message.h → diff_stats.h} +7 -6
- data/vendor/libgit2/src/diff_tform.c +18 -16
- data/vendor/libgit2/src/diff_xdiff.c +7 -10
- data/vendor/libgit2/src/diff_xdiff.h +1 -1
- data/vendor/libgit2/src/email.c +315 -0
- data/vendor/libgit2/src/email.h +25 -0
- data/vendor/libgit2/src/errors.c +37 -32
- data/vendor/libgit2/src/features.h.in +11 -2
- data/vendor/libgit2/src/fetch.c +77 -26
- data/vendor/libgit2/src/fetch.h +1 -1
- data/vendor/libgit2/src/fetchhead.c +27 -23
- data/vendor/libgit2/src/filebuf.c +36 -34
- data/vendor/libgit2/src/filebuf.h +1 -1
- data/vendor/libgit2/src/filter.c +278 -132
- data/vendor/libgit2/src/filter.h +46 -6
- data/vendor/libgit2/src/fs_path.c +2071 -0
- data/vendor/libgit2/src/fs_path.h +772 -0
- data/vendor/libgit2/src/futils.c +96 -90
- data/vendor/libgit2/src/futils.h +27 -15
- data/vendor/libgit2/src/graph.c +64 -9
- data/vendor/libgit2/src/hash/sha1/collisiondetect.c +5 -5
- data/vendor/libgit2/src/hash/sha1/common_crypto.c +5 -5
- data/vendor/libgit2/src/hash/sha1/generic.c +2 -2
- data/vendor/libgit2/src/hash/sha1/generic.h +1 -1
- data/vendor/libgit2/src/hash/sha1/mbedtls.c +13 -13
- data/vendor/libgit2/src/hash/sha1/openssl.c +5 -5
- data/vendor/libgit2/src/hash/sha1/sha1dc/sha1.c +9 -11
- data/vendor/libgit2/src/hash/sha1/win32.c +21 -17
- data/vendor/libgit2/src/hash/sha1.h +3 -1
- data/vendor/libgit2/src/hash.c +71 -36
- data/vendor/libgit2/src/hash.h +13 -13
- data/vendor/libgit2/src/hashsig.c +23 -10
- data/vendor/libgit2/src/ident.c +30 -20
- data/vendor/libgit2/src/ignore.c +63 -46
- data/vendor/libgit2/src/ignore.h +2 -2
- data/vendor/libgit2/src/index.c +184 -149
- data/vendor/libgit2/src/index.h +7 -4
- data/vendor/libgit2/src/indexer.c +143 -89
- data/vendor/libgit2/src/integer.h +64 -2
- data/vendor/libgit2/src/iterator.c +93 -73
- data/vendor/libgit2/src/iterator.h +6 -6
- data/vendor/libgit2/src/khash.h +3 -12
- data/vendor/libgit2/src/{settings.c → libgit2.c} +165 -56
- data/vendor/libgit2/src/libgit2.h +15 -0
- data/vendor/libgit2/src/mailmap.c +60 -45
- data/vendor/libgit2/src/map.h +3 -3
- data/vendor/libgit2/src/merge.c +104 -61
- data/vendor/libgit2/src/merge.h +3 -15
- data/vendor/libgit2/src/merge_driver.c +21 -15
- data/vendor/libgit2/src/merge_file.c +24 -6
- data/vendor/libgit2/src/message.c +21 -8
- data/vendor/libgit2/src/midx.c +501 -18
- data/vendor/libgit2/src/midx.h +29 -2
- data/vendor/libgit2/src/mwindow.c +103 -59
- data/vendor/libgit2/src/mwindow.h +3 -3
- data/vendor/libgit2/src/net.c +405 -71
- data/vendor/libgit2/src/net.h +26 -5
- data/vendor/libgit2/src/netops.c +7 -5
- data/vendor/libgit2/src/netops.h +3 -3
- data/vendor/libgit2/src/notes.c +40 -49
- data/vendor/libgit2/src/object.c +68 -20
- data/vendor/libgit2/src/object.h +1 -1
- data/vendor/libgit2/src/odb.c +320 -80
- data/vendor/libgit2/src/odb.h +17 -3
- data/vendor/libgit2/src/odb_loose.c +96 -86
- data/vendor/libgit2/src/odb_mempack.c +19 -6
- data/vendor/libgit2/src/odb_pack.c +402 -125
- data/vendor/libgit2/src/oid.c +16 -8
- data/vendor/libgit2/src/oid.h +15 -0
- data/vendor/libgit2/src/oidarray.c +10 -1
- data/vendor/libgit2/src/pack-objects.c +90 -69
- data/vendor/libgit2/src/pack-objects.h +11 -6
- data/vendor/libgit2/src/pack.c +337 -127
- data/vendor/libgit2/src/pack.h +25 -7
- data/vendor/libgit2/src/patch.c +17 -10
- data/vendor/libgit2/src/patch.h +1 -0
- data/vendor/libgit2/src/patch_generate.c +29 -13
- data/vendor/libgit2/src/patch_generate.h +5 -5
- data/vendor/libgit2/src/patch_parse.c +26 -25
- data/vendor/libgit2/src/path.c +86 -1768
- data/vendor/libgit2/src/path.h +39 -635
- data/vendor/libgit2/src/pathspec.c +12 -12
- data/vendor/libgit2/src/pathspec.h +2 -2
- data/vendor/libgit2/src/pool.c +13 -7
- data/vendor/libgit2/src/posix.c +14 -6
- data/vendor/libgit2/src/posix.h +1 -0
- data/vendor/libgit2/src/pqueue.h +1 -1
- data/vendor/libgit2/src/proxy.c +4 -1
- data/vendor/libgit2/src/proxy.h +1 -1
- data/vendor/libgit2/src/push.c +30 -35
- data/vendor/libgit2/src/push.h +4 -16
- data/vendor/libgit2/src/rand.c +226 -0
- data/vendor/libgit2/src/rand.h +37 -0
- data/vendor/libgit2/src/reader.c +18 -14
- data/vendor/libgit2/src/reader.h +2 -2
- data/vendor/libgit2/src/rebase.c +177 -132
- data/vendor/libgit2/src/refdb.c +30 -13
- data/vendor/libgit2/src/refdb_fs.c +548 -222
- data/vendor/libgit2/src/reflog.c +19 -14
- data/vendor/libgit2/src/refs.c +107 -72
- data/vendor/libgit2/src/refs.h +2 -2
- data/vendor/libgit2/src/refspec.c +53 -38
- data/vendor/libgit2/src/refspec.h +5 -2
- data/vendor/libgit2/src/regexp.c +1 -1
- data/vendor/libgit2/src/remote.c +960 -486
- data/vendor/libgit2/src/remote.h +16 -10
- data/vendor/libgit2/src/repository.c +702 -422
- data/vendor/libgit2/src/repository.h +26 -8
- data/vendor/libgit2/src/reset.c +16 -12
- data/vendor/libgit2/src/revert.c +16 -12
- data/vendor/libgit2/src/revparse.c +66 -48
- data/vendor/libgit2/src/revwalk.c +39 -22
- data/vendor/libgit2/src/runtime.c +162 -0
- data/vendor/libgit2/src/runtime.h +62 -0
- data/vendor/libgit2/src/settings.h +11 -0
- data/vendor/libgit2/src/signature.c +18 -11
- data/vendor/libgit2/src/signature.h +1 -1
- data/vendor/libgit2/src/sortedcache.c +1 -1
- data/vendor/libgit2/src/sortedcache.h +10 -8
- data/vendor/libgit2/src/stash.c +39 -38
- data/vendor/libgit2/src/status.c +11 -5
- data/vendor/libgit2/src/{buffer.c → str.c} +459 -136
- data/vendor/libgit2/src/str.h +357 -0
- data/vendor/libgit2/src/strarray.c +2 -1
- data/vendor/libgit2/src/streams/mbedtls.c +22 -23
- data/vendor/libgit2/src/streams/mbedtls.h +1 -1
- data/vendor/libgit2/src/streams/openssl.c +101 -201
- data/vendor/libgit2/src/streams/openssl.h +9 -1
- data/vendor/libgit2/src/streams/openssl_dynamic.c +309 -0
- data/vendor/libgit2/src/streams/openssl_dynamic.h +348 -0
- data/vendor/libgit2/src/streams/openssl_legacy.c +203 -0
- data/vendor/libgit2/src/streams/openssl_legacy.h +63 -0
- data/vendor/libgit2/src/streams/registry.c +5 -6
- data/vendor/libgit2/src/streams/socket.c +6 -2
- data/vendor/libgit2/src/streams/stransport.c +6 -3
- data/vendor/libgit2/src/streams/tls.c +5 -3
- data/vendor/libgit2/src/submodule.c +290 -212
- data/vendor/libgit2/src/submodule.h +10 -10
- data/vendor/libgit2/src/sysdir.c +70 -56
- data/vendor/libgit2/src/sysdir.h +15 -10
- data/vendor/libgit2/src/tag.c +72 -34
- data/vendor/libgit2/src/thread.c +140 -0
- data/vendor/libgit2/src/thread.h +479 -0
- data/vendor/libgit2/src/threadstate.c +84 -0
- data/vendor/libgit2/src/threadstate.h +24 -0
- data/vendor/libgit2/src/trace.c +3 -16
- data/vendor/libgit2/src/trace.h +17 -30
- data/vendor/libgit2/src/trailer.c +2 -2
- data/vendor/libgit2/src/transaction.c +20 -9
- data/vendor/libgit2/src/transport.c +13 -13
- data/vendor/libgit2/src/transports/auth.c +8 -10
- data/vendor/libgit2/src/transports/auth.h +2 -3
- data/vendor/libgit2/src/transports/auth_negotiate.c +23 -17
- data/vendor/libgit2/src/transports/auth_ntlm.c +20 -16
- data/vendor/libgit2/src/transports/auth_ntlm.h +0 -1
- data/vendor/libgit2/src/transports/credential.c +15 -7
- data/vendor/libgit2/src/transports/git.c +10 -14
- data/vendor/libgit2/src/transports/http.c +56 -34
- data/vendor/libgit2/src/transports/http.h +3 -3
- data/vendor/libgit2/src/transports/httpclient.c +106 -79
- data/vendor/libgit2/src/transports/httpclient.h +1 -1
- data/vendor/libgit2/src/transports/local.c +127 -119
- data/vendor/libgit2/src/transports/smart.c +61 -144
- data/vendor/libgit2/src/transports/smart.h +26 -32
- data/vendor/libgit2/src/transports/smart_pkt.c +33 -33
- data/vendor/libgit2/src/transports/smart_protocol.c +68 -44
- data/vendor/libgit2/src/transports/ssh.c +100 -131
- data/vendor/libgit2/src/transports/winhttp.c +86 -82
- data/vendor/libgit2/src/tree-cache.c +5 -5
- data/vendor/libgit2/src/tree-cache.h +2 -2
- data/vendor/libgit2/src/tree.c +150 -116
- data/vendor/libgit2/src/tree.h +1 -0
- data/vendor/libgit2/src/tsort.c +0 -2
- data/vendor/libgit2/src/unix/map.c +3 -3
- data/vendor/libgit2/src/unix/posix.h +1 -4
- data/vendor/libgit2/src/unix/pthread.h +2 -1
- data/vendor/libgit2/src/unix/realpath.c +0 -2
- data/vendor/libgit2/src/utf8.c +150 -0
- data/vendor/libgit2/src/utf8.h +52 -0
- data/vendor/libgit2/src/util.c +68 -144
- data/vendor/libgit2/src/util.h +36 -68
- data/vendor/libgit2/src/vector.c +23 -19
- data/vendor/libgit2/src/vector.h +5 -3
- data/vendor/libgit2/src/win32/findfile.c +172 -114
- data/vendor/libgit2/src/win32/findfile.h +7 -4
- data/vendor/libgit2/src/win32/map.c +1 -1
- data/vendor/libgit2/src/win32/msvc-compat.h +9 -1
- data/vendor/libgit2/src/win32/path_w32.c +162 -33
- data/vendor/libgit2/src/win32/path_w32.h +2 -1
- data/vendor/libgit2/src/win32/posix.h +6 -7
- data/vendor/libgit2/src/win32/posix_w32.c +26 -33
- data/vendor/libgit2/src/win32/precompiled.h +0 -1
- data/vendor/libgit2/src/win32/reparse.h +4 -4
- data/vendor/libgit2/src/win32/thread.c +24 -15
- data/vendor/libgit2/src/win32/thread.h +1 -1
- data/vendor/libgit2/src/win32/w32_buffer.c +5 -6
- data/vendor/libgit2/src/win32/w32_buffer.h +2 -3
- data/vendor/libgit2/src/win32/w32_common.h +18 -9
- data/vendor/libgit2/src/win32/{w32_crtdbg_stacktrace.c → w32_leakcheck.c} +269 -33
- data/vendor/libgit2/src/win32/w32_leakcheck.h +222 -0
- data/vendor/libgit2/src/win32/w32_util.h +6 -6
- data/vendor/libgit2/src/worktree.c +138 -105
- data/vendor/libgit2/src/worktree.h +1 -1
- data/vendor/libgit2/src/xdiff/git-xdiff.h +53 -0
- data/vendor/libgit2/src/xdiff/xdiff.h +15 -15
- data/vendor/libgit2/src/xdiff/xdiffi.c +134 -108
- data/vendor/libgit2/src/xdiff/xemit.c +23 -7
- data/vendor/libgit2/src/xdiff/xhistogram.c +87 -78
- data/vendor/libgit2/src/xdiff/xinclude.h +1 -12
- data/vendor/libgit2/src/xdiff/xmerge.c +104 -117
- data/vendor/libgit2/src/xdiff/xpatience.c +6 -17
- data/vendor/libgit2/src/xdiff/xprepare.c +15 -20
- data/vendor/libgit2/src/xdiff/xutils.c +18 -7
- data/vendor/libgit2/src/zstream.c +6 -6
- data/vendor/libgit2/src/zstream.h +4 -4
- metadata +60 -24
- data/vendor/libgit2/src/allocators/win32_crtdbg.c +0 -118
- data/vendor/libgit2/src/buf_text.c +0 -316
- data/vendor/libgit2/src/buf_text.h +0 -122
- data/vendor/libgit2/src/buffer.h +0 -222
- data/vendor/libgit2/src/global.c +0 -363
- data/vendor/libgit2/src/global.h +0 -41
- data/vendor/libgit2/src/thread-utils.c +0 -58
- data/vendor/libgit2/src/thread-utils.h +0 -369
- data/vendor/libgit2/src/win32/w32_crtdbg_stacktrace.h +0 -127
- data/vendor/libgit2/src/win32/w32_stack.c +0 -188
- data/vendor/libgit2/src/win32/w32_stack.h +0 -140
@@ -11,9 +11,7 @@
|
|
11
11
|
#include <libssh2.h>
|
12
12
|
#endif
|
13
13
|
|
14
|
-
#include "
|
15
|
-
#include "git2.h"
|
16
|
-
#include "buffer.h"
|
14
|
+
#include "runtime.h"
|
17
15
|
#include "net.h"
|
18
16
|
#include "netops.h"
|
19
17
|
#include "smart.h"
|
@@ -26,8 +24,6 @@
|
|
26
24
|
|
27
25
|
#define OWNING_SUBTRANSPORT(s) ((ssh_subtransport *)(s)->parent.subtransport)
|
28
26
|
|
29
|
-
static const char *ssh_prefixes[] = { "ssh://", "ssh+git://", "git+ssh://" };
|
30
|
-
|
31
27
|
static const char cmd_uploadpack[] = "git-upload-pack";
|
32
28
|
static const char cmd_receivepack[] = "git-receive-pack";
|
33
29
|
|
@@ -37,7 +33,7 @@ typedef struct {
|
|
37
33
|
LIBSSH2_SESSION *session;
|
38
34
|
LIBSSH2_CHANNEL *channel;
|
39
35
|
const char *cmd;
|
40
|
-
|
36
|
+
git_net_url url;
|
41
37
|
unsigned sent_command : 1;
|
42
38
|
} ssh_stream;
|
43
39
|
|
@@ -65,42 +61,26 @@ static void ssh_error(LIBSSH2_SESSION *session, const char *errmsg)
|
|
65
61
|
*
|
66
62
|
* For example: git-upload-pack '/libgit2/libgit2'
|
67
63
|
*/
|
68
|
-
static int gen_proto(
|
64
|
+
static int gen_proto(git_str *request, const char *cmd, git_net_url *url)
|
69
65
|
{
|
70
66
|
const char *repo;
|
71
|
-
int len;
|
72
|
-
size_t i;
|
73
|
-
|
74
|
-
for (i = 0; i < ARRAY_SIZE(ssh_prefixes); ++i) {
|
75
|
-
const char *p = ssh_prefixes[i];
|
76
67
|
|
77
|
-
|
78
|
-
url = url + strlen(p);
|
79
|
-
repo = strchr(url, '/');
|
80
|
-
if (repo && repo[1] == '~')
|
81
|
-
++repo;
|
68
|
+
repo = url->path;
|
82
69
|
|
83
|
-
|
84
|
-
|
85
|
-
}
|
86
|
-
repo = strchr(url, ':');
|
87
|
-
if (repo) repo++;
|
70
|
+
if (repo && repo[0] == '/' && repo[1] == '~')
|
71
|
+
repo++;
|
88
72
|
|
89
|
-
|
90
|
-
if (!repo) {
|
73
|
+
if (!repo || !repo[0]) {
|
91
74
|
git_error_set(GIT_ERROR_NET, "malformed git protocol URL");
|
92
75
|
return -1;
|
93
76
|
}
|
94
77
|
|
95
|
-
|
78
|
+
git_str_puts(request, cmd);
|
79
|
+
git_str_puts(request, " '");
|
80
|
+
git_str_puts(request, repo);
|
81
|
+
git_str_puts(request, "'");
|
96
82
|
|
97
|
-
|
98
|
-
git_buf_puts(request, cmd);
|
99
|
-
git_buf_puts(request, " '");
|
100
|
-
git_buf_decode_percent(request, repo, strlen(repo));
|
101
|
-
git_buf_puts(request, "'");
|
102
|
-
|
103
|
-
if (git_buf_oom(request))
|
83
|
+
if (git_str_oom(request))
|
104
84
|
return -1;
|
105
85
|
|
106
86
|
return 0;
|
@@ -109,9 +89,9 @@ done:
|
|
109
89
|
static int send_command(ssh_stream *s)
|
110
90
|
{
|
111
91
|
int error;
|
112
|
-
|
92
|
+
git_str request = GIT_STR_INIT;
|
113
93
|
|
114
|
-
error = gen_proto(&request, s->cmd, s->url);
|
94
|
+
error = gen_proto(&request, s->cmd, &s->url);
|
115
95
|
if (error < 0)
|
116
96
|
goto cleanup;
|
117
97
|
|
@@ -124,7 +104,7 @@ static int send_command(ssh_stream *s)
|
|
124
104
|
s->sent_command = 1;
|
125
105
|
|
126
106
|
cleanup:
|
127
|
-
|
107
|
+
git_str_dispose(&request);
|
128
108
|
return error;
|
129
109
|
}
|
130
110
|
|
@@ -226,19 +206,18 @@ static void ssh_stream_free(git_smart_subtransport_stream *stream)
|
|
226
206
|
s->io = NULL;
|
227
207
|
}
|
228
208
|
|
229
|
-
|
209
|
+
git_net_url_dispose(&s->url);
|
230
210
|
git__free(s);
|
231
211
|
}
|
232
212
|
|
233
213
|
static int ssh_stream_alloc(
|
234
214
|
ssh_subtransport *t,
|
235
|
-
const char *url,
|
236
215
|
const char *cmd,
|
237
216
|
git_smart_subtransport_stream **stream)
|
238
217
|
{
|
239
218
|
ssh_stream *s;
|
240
219
|
|
241
|
-
|
220
|
+
GIT_ASSERT_ARG(stream);
|
242
221
|
|
243
222
|
s = git__calloc(sizeof(ssh_stream), 1);
|
244
223
|
GIT_ERROR_CHECK_ALLOC(s);
|
@@ -250,47 +229,10 @@ static int ssh_stream_alloc(
|
|
250
229
|
|
251
230
|
s->cmd = cmd;
|
252
231
|
|
253
|
-
s->url = git__strdup(url);
|
254
|
-
if (!s->url) {
|
255
|
-
git__free(s);
|
256
|
-
return -1;
|
257
|
-
}
|
258
|
-
|
259
232
|
*stream = &s->parent;
|
260
233
|
return 0;
|
261
234
|
}
|
262
235
|
|
263
|
-
static int git_ssh_extract_url_parts(
|
264
|
-
git_net_url *urldata,
|
265
|
-
const char *url)
|
266
|
-
{
|
267
|
-
char *colon, *at;
|
268
|
-
const char *start;
|
269
|
-
|
270
|
-
colon = strchr(url, ':');
|
271
|
-
|
272
|
-
|
273
|
-
at = strchr(url, '@');
|
274
|
-
if (at) {
|
275
|
-
start = at + 1;
|
276
|
-
urldata->username = git__substrdup(url, at - url);
|
277
|
-
GIT_ERROR_CHECK_ALLOC(urldata->username);
|
278
|
-
} else {
|
279
|
-
start = url;
|
280
|
-
urldata->username = NULL;
|
281
|
-
}
|
282
|
-
|
283
|
-
if (colon == NULL || (colon < start)) {
|
284
|
-
git_error_set(GIT_ERROR_NET, "malformed URL");
|
285
|
-
return -1;
|
286
|
-
}
|
287
|
-
|
288
|
-
urldata->host = git__substrdup(start, colon - start);
|
289
|
-
GIT_ERROR_CHECK_ALLOC(urldata->host);
|
290
|
-
|
291
|
-
return 0;
|
292
|
-
}
|
293
|
-
|
294
236
|
static int ssh_agent_auth(LIBSSH2_SESSION *session, git_credential_ssh_key *c) {
|
295
237
|
int rc = LIBSSH2_ERROR_NONE;
|
296
238
|
|
@@ -404,8 +346,8 @@ static int _git_ssh_authenticate_session(
|
|
404
346
|
case GIT_CREDENTIAL_SSH_MEMORY: {
|
405
347
|
git_credential_ssh_key *c = (git_credential_ssh_key *)cred;
|
406
348
|
|
407
|
-
|
408
|
-
|
349
|
+
GIT_ASSERT(c->username);
|
350
|
+
GIT_ASSERT(c->privatekey);
|
409
351
|
|
410
352
|
rc = libssh2_userauth_publickey_frommemory(
|
411
353
|
session,
|
@@ -443,11 +385,15 @@ static int request_creds(git_credential **out, ssh_subtransport *t, const char *
|
|
443
385
|
int error, no_callback = 0;
|
444
386
|
git_credential *cred = NULL;
|
445
387
|
|
446
|
-
if (!t->owner->
|
388
|
+
if (!t->owner->connect_opts.callbacks.credentials) {
|
447
389
|
no_callback = 1;
|
448
390
|
} else {
|
449
|
-
error = t->owner->
|
450
|
-
|
391
|
+
error = t->owner->connect_opts.callbacks.credentials(
|
392
|
+
&cred,
|
393
|
+
t->owner->url,
|
394
|
+
user,
|
395
|
+
auth_methods,
|
396
|
+
t->owner->connect_opts.callbacks.payload);
|
451
397
|
|
452
398
|
if (error == GIT_PASSTHROUGH) {
|
453
399
|
no_callback = 1;
|
@@ -461,13 +407,13 @@ static int request_creds(git_credential **out, ssh_subtransport *t, const char *
|
|
461
407
|
|
462
408
|
if (no_callback) {
|
463
409
|
git_error_set(GIT_ERROR_SSH, "authentication required but no callback set");
|
464
|
-
return
|
410
|
+
return GIT_EAUTH;
|
465
411
|
}
|
466
412
|
|
467
413
|
if (!(cred->credtype & auth_methods)) {
|
468
414
|
cred->free(cred);
|
469
|
-
git_error_set(GIT_ERROR_SSH, "callback returned unsupported credentials type");
|
470
|
-
return
|
415
|
+
git_error_set(GIT_ERROR_SSH, "authentication callback returned unsupported credentials type");
|
416
|
+
return GIT_EAUTH;
|
471
417
|
}
|
472
418
|
|
473
419
|
*out = cred;
|
@@ -476,14 +422,14 @@ static int request_creds(git_credential **out, ssh_subtransport *t, const char *
|
|
476
422
|
}
|
477
423
|
|
478
424
|
static int _git_ssh_session_create(
|
479
|
-
LIBSSH2_SESSION**
|
425
|
+
LIBSSH2_SESSION **session,
|
480
426
|
git_stream *io)
|
481
427
|
{
|
482
428
|
int rc = 0;
|
483
|
-
LIBSSH2_SESSION*
|
429
|
+
LIBSSH2_SESSION *s;
|
484
430
|
git_socket_stream *socket = GIT_CONTAINER_OF(io, git_socket_stream, parent);
|
485
431
|
|
486
|
-
|
432
|
+
GIT_ASSERT_ARG(session);
|
487
433
|
|
488
434
|
s = libssh2_session_init();
|
489
435
|
if (!s) {
|
@@ -516,56 +462,80 @@ static int _git_ssh_setup_conn(
|
|
516
462
|
const char *cmd,
|
517
463
|
git_smart_subtransport_stream **stream)
|
518
464
|
{
|
519
|
-
git_net_url urldata = GIT_NET_URL_INIT;
|
520
465
|
int auth_methods, error = 0;
|
521
|
-
size_t i;
|
522
466
|
ssh_stream *s;
|
523
467
|
git_credential *cred = NULL;
|
524
|
-
LIBSSH2_SESSION*
|
525
|
-
LIBSSH2_CHANNEL*
|
468
|
+
LIBSSH2_SESSION *session=NULL;
|
469
|
+
LIBSSH2_CHANNEL *channel=NULL;
|
526
470
|
|
527
471
|
t->current_stream = NULL;
|
528
472
|
|
529
473
|
*stream = NULL;
|
530
|
-
if (ssh_stream_alloc(t,
|
474
|
+
if (ssh_stream_alloc(t, cmd, stream) < 0)
|
531
475
|
return -1;
|
532
476
|
|
533
477
|
s = (ssh_stream *)*stream;
|
534
478
|
s->session = NULL;
|
535
479
|
s->channel = NULL;
|
536
480
|
|
537
|
-
|
538
|
-
|
481
|
+
if (git_net_str_is_url(url))
|
482
|
+
error = git_net_url_parse(&s->url, url);
|
483
|
+
else
|
484
|
+
error = git_net_url_parse_scp(&s->url, url);
|
539
485
|
|
540
|
-
|
541
|
-
if ((error = git_net_url_parse(&urldata, url)) < 0)
|
542
|
-
goto done;
|
543
|
-
|
544
|
-
goto post_extract;
|
545
|
-
}
|
546
|
-
}
|
547
|
-
if ((error = git_ssh_extract_url_parts(&urldata, url)) < 0)
|
486
|
+
if (error < 0)
|
548
487
|
goto done;
|
549
488
|
|
550
|
-
if (
|
551
|
-
urldata.port = git__strdup(SSH_DEFAULT_PORT);
|
552
|
-
|
553
|
-
GIT_ERROR_CHECK_ALLOC(urldata.port);
|
554
|
-
|
555
|
-
post_extract:
|
556
|
-
if ((error = git_socket_stream_new(&s->io, urldata.host, urldata.port)) < 0 ||
|
489
|
+
if ((error = git_socket_stream_new(&s->io, s->url.host, s->url.port)) < 0 ||
|
557
490
|
(error = git_stream_connect(s->io)) < 0)
|
558
491
|
goto done;
|
559
492
|
|
560
493
|
if ((error = _git_ssh_session_create(&session, s->io)) < 0)
|
561
494
|
goto done;
|
562
495
|
|
563
|
-
if (t->owner->
|
496
|
+
if (t->owner->connect_opts.callbacks.certificate_check != NULL) {
|
564
497
|
git_cert_hostkey cert = {{ 0 }}, *cert_ptr;
|
565
498
|
const char *key;
|
499
|
+
size_t cert_len;
|
500
|
+
int cert_type;
|
566
501
|
|
567
502
|
cert.parent.cert_type = GIT_CERT_HOSTKEY_LIBSSH2;
|
568
503
|
|
504
|
+
key = libssh2_session_hostkey(session, &cert_len, &cert_type);
|
505
|
+
if (key != NULL) {
|
506
|
+
cert.type |= GIT_CERT_SSH_RAW;
|
507
|
+
cert.hostkey = key;
|
508
|
+
cert.hostkey_len = cert_len;
|
509
|
+
switch (cert_type) {
|
510
|
+
case LIBSSH2_HOSTKEY_TYPE_RSA:
|
511
|
+
cert.raw_type = GIT_CERT_SSH_RAW_TYPE_RSA;
|
512
|
+
break;
|
513
|
+
case LIBSSH2_HOSTKEY_TYPE_DSS:
|
514
|
+
cert.raw_type = GIT_CERT_SSH_RAW_TYPE_DSS;
|
515
|
+
break;
|
516
|
+
|
517
|
+
#ifdef LIBSSH2_HOSTKEY_TYPE_ECDSA_256
|
518
|
+
case LIBSSH2_HOSTKEY_TYPE_ECDSA_256:
|
519
|
+
cert.raw_type = GIT_CERT_SSH_RAW_TYPE_KEY_ECDSA_256;
|
520
|
+
break;
|
521
|
+
case LIBSSH2_HOSTKEY_TYPE_ECDSA_384:
|
522
|
+
cert.raw_type = GIT_CERT_SSH_RAW_TYPE_KEY_ECDSA_384;
|
523
|
+
break;
|
524
|
+
case LIBSSH2_KNOWNHOST_KEY_ECDSA_521:
|
525
|
+
cert.raw_type = GIT_CERT_SSH_RAW_TYPE_KEY_ECDSA_521;
|
526
|
+
break;
|
527
|
+
#endif
|
528
|
+
|
529
|
+
#ifdef LIBSSH2_HOSTKEY_TYPE_ED25519
|
530
|
+
case LIBSSH2_HOSTKEY_TYPE_ED25519:
|
531
|
+
cert.raw_type = GIT_CERT_SSH_RAW_TYPE_KEY_ED25519;
|
532
|
+
break;
|
533
|
+
#endif
|
534
|
+
default:
|
535
|
+
cert.raw_type = GIT_CERT_SSH_RAW_TYPE_UNKNOWN;
|
536
|
+
}
|
537
|
+
}
|
538
|
+
|
569
539
|
#ifdef LIBSSH2_HOSTKEY_HASH_SHA256
|
570
540
|
key = libssh2_hostkey_hash(session, LIBSSH2_HOSTKEY_HASH_SHA256);
|
571
541
|
if (key != NULL) {
|
@@ -597,7 +567,11 @@ post_extract:
|
|
597
567
|
|
598
568
|
cert_ptr = &cert;
|
599
569
|
|
600
|
-
error = t->owner->
|
570
|
+
error = t->owner->connect_opts.callbacks.certificate_check(
|
571
|
+
(git_cert *)cert_ptr,
|
572
|
+
0,
|
573
|
+
s->url.host,
|
574
|
+
t->owner->connect_opts.callbacks.payload);
|
601
575
|
|
602
576
|
if (error < 0 && error != GIT_PASSTHROUGH) {
|
603
577
|
if (!git_error_last())
|
@@ -608,21 +582,21 @@ post_extract:
|
|
608
582
|
}
|
609
583
|
|
610
584
|
/* we need the username to ask for auth methods */
|
611
|
-
if (!
|
585
|
+
if (!s->url.username) {
|
612
586
|
if ((error = request_creds(&cred, t, NULL, GIT_CREDENTIAL_USERNAME)) < 0)
|
613
587
|
goto done;
|
614
588
|
|
615
|
-
|
589
|
+
s->url.username = git__strdup(((git_credential_username *) cred)->username);
|
616
590
|
cred->free(cred);
|
617
591
|
cred = NULL;
|
618
|
-
if (!
|
592
|
+
if (!s->url.username)
|
619
593
|
goto done;
|
620
|
-
} else if (
|
621
|
-
if ((error = git_credential_userpass_plaintext_new(&cred,
|
594
|
+
} else if (s->url.username && s->url.password) {
|
595
|
+
if ((error = git_credential_userpass_plaintext_new(&cred, s->url.username, s->url.password)) < 0)
|
622
596
|
goto done;
|
623
597
|
}
|
624
598
|
|
625
|
-
if ((error = list_auth_methods(&auth_methods, session,
|
599
|
+
if ((error = list_auth_methods(&auth_methods, session, s->url.username)) < 0)
|
626
600
|
goto done;
|
627
601
|
|
628
602
|
error = GIT_EAUTH;
|
@@ -636,10 +610,10 @@ post_extract:
|
|
636
610
|
cred = NULL;
|
637
611
|
}
|
638
612
|
|
639
|
-
if ((error = request_creds(&cred, t,
|
613
|
+
if ((error = request_creds(&cred, t, s->url.username, auth_methods)) < 0)
|
640
614
|
goto done;
|
641
615
|
|
642
|
-
if (strcmp(
|
616
|
+
if (strcmp(s->url.username, git_credential_get_username(cred))) {
|
643
617
|
git_error_set(GIT_ERROR_SSH, "username does not match previous request");
|
644
618
|
error = -1;
|
645
619
|
goto done;
|
@@ -649,7 +623,7 @@ post_extract:
|
|
649
623
|
|
650
624
|
if (error == GIT_EAUTH) {
|
651
625
|
/* refresh auth methods */
|
652
|
-
if ((error = list_auth_methods(&auth_methods, session,
|
626
|
+
if ((error = list_auth_methods(&auth_methods, session, s->url.username)) < 0)
|
653
627
|
goto done;
|
654
628
|
else
|
655
629
|
error = GIT_EAUTH;
|
@@ -684,8 +658,6 @@ done:
|
|
684
658
|
if (cred)
|
685
659
|
cred->free(cred);
|
686
660
|
|
687
|
-
git_net_url_dispose(&urldata);
|
688
|
-
|
689
661
|
return error;
|
690
662
|
}
|
691
663
|
|
@@ -772,7 +744,7 @@ static int _ssh_close(git_smart_subtransport *subtransport)
|
|
772
744
|
{
|
773
745
|
ssh_subtransport *t = GIT_CONTAINER_OF(subtransport, ssh_subtransport, parent);
|
774
746
|
|
775
|
-
|
747
|
+
GIT_ASSERT(!t->current_stream);
|
776
748
|
|
777
749
|
GIT_UNUSED(t);
|
778
750
|
|
@@ -783,8 +755,6 @@ static void _ssh_free(git_smart_subtransport *subtransport)
|
|
783
755
|
{
|
784
756
|
ssh_subtransport *t = GIT_CONTAINER_OF(subtransport, ssh_subtransport, parent);
|
785
757
|
|
786
|
-
assert(!t->current_stream);
|
787
|
-
|
788
758
|
git__free(t->cmd_uploadpack);
|
789
759
|
git__free(t->cmd_receivepack);
|
790
760
|
git__free(t);
|
@@ -805,7 +775,7 @@ static int list_auth_methods(int *out, LIBSSH2_SESSION *session, const char *use
|
|
805
775
|
/* either error, or the remote accepts NONE auth, which is bizarre, let's punt */
|
806
776
|
if (list == NULL && !libssh2_userauth_authenticated(session)) {
|
807
777
|
ssh_error(session, "Failed to retrieve list of SSH authentication methods");
|
808
|
-
return
|
778
|
+
return GIT_EAUTH;
|
809
779
|
}
|
810
780
|
|
811
781
|
ptr = list;
|
@@ -835,7 +805,7 @@ static int list_auth_methods(int *out, LIBSSH2_SESSION *session, const char *use
|
|
835
805
|
continue;
|
836
806
|
}
|
837
807
|
|
838
|
-
/*
|
808
|
+
/* Skip it if we don't know it */
|
839
809
|
ptr = strchr(ptr, ',');
|
840
810
|
}
|
841
811
|
|
@@ -849,7 +819,7 @@ int git_smart_subtransport_ssh(
|
|
849
819
|
#ifdef GIT_SSH
|
850
820
|
ssh_subtransport *t;
|
851
821
|
|
852
|
-
|
822
|
+
GIT_ASSERT_ARG(out);
|
853
823
|
|
854
824
|
GIT_UNUSED(param);
|
855
825
|
|
@@ -867,7 +837,7 @@ int git_smart_subtransport_ssh(
|
|
867
837
|
GIT_UNUSED(owner);
|
868
838
|
GIT_UNUSED(param);
|
869
839
|
|
870
|
-
|
840
|
+
GIT_ASSERT_ARG(out);
|
871
841
|
*out = NULL;
|
872
842
|
|
873
843
|
git_error_set(GIT_ERROR_INVALID, "cannot create SSH transport. Library was built without SSH support");
|
@@ -911,7 +881,7 @@ int git_transport_ssh_with_paths(git_transport **out, git_remote *owner, void *p
|
|
911
881
|
GIT_UNUSED(owner);
|
912
882
|
GIT_UNUSED(payload);
|
913
883
|
|
914
|
-
|
884
|
+
GIT_ASSERT_ARG(out);
|
915
885
|
*out = NULL;
|
916
886
|
|
917
887
|
git_error_set(GIT_ERROR_INVALID, "cannot create SSH transport. Library was built without SSH support");
|
@@ -934,8 +904,7 @@ int git_transport_ssh_global_init(void)
|
|
934
904
|
return -1;
|
935
905
|
}
|
936
906
|
|
937
|
-
|
938
|
-
return 0;
|
907
|
+
return git_runtime_shutdown_register(shutdown_ssh);
|
939
908
|
|
940
909
|
#else
|
941
910
|
|