File tree Expand file tree Collapse file tree 5 files changed +12
-42
lines changed
Expand file tree Collapse file tree 5 files changed +12
-42
lines changed Original file line number Diff line number Diff line change @@ -490,23 +490,4 @@ int git_mbedtls_stream_global_init(void)
490490 return 0 ;
491491}
492492
493- int git_mbedtls_stream_new (git_stream * * out , const char * host , const char * port )
494- {
495- GIT_UNUSED (out );
496- GIT_UNUSED (host );
497- GIT_UNUSED (port );
498-
499- giterr_set (GITERR_SSL , "mbedTLS is not supported in this version" );
500- return -1 ;
501- }
502-
503- int git_mbedtls__set_cert_location (const char * path , int is_dir )
504- {
505- GIT_UNUSED (path );
506- GIT_UNUSED (is_dir );
507-
508- giterr_set (GITERR_SSL , "mbedTLS is not supported in this version" );
509- return -1 ;
510- }
511-
512493#endif
Original file line number Diff line number Diff line change 1313
1414extern int git_mbedtls_stream_global_init (void );
1515
16+ #ifdef GIT_MBEDTLS
17+ extern int git_mbedtls__set_cert_location (const char * path , int is_dir );
18+
1619extern int git_mbedtls_stream_new (git_stream * * out , const char * host , const char * port );
1720extern int git_mbedtls_stream_wrap (git_stream * * out , git_stream * in , const char * host );
18-
19- extern int git_mbedtls__set_cert_location (const char * path , int is_dir );
21+ #endif
2022
2123#endif
Original file line number Diff line number Diff line change @@ -799,23 +799,4 @@ int git_openssl_set_locking(void)
799799 return -1 ;
800800}
801801
802- int git_openssl_stream_new (git_stream * * out , const char * host , const char * port )
803- {
804- GIT_UNUSED (out );
805- GIT_UNUSED (host );
806- GIT_UNUSED (port );
807-
808- giterr_set (GITERR_SSL , "openssl is not supported in this version" );
809- return -1 ;
810- }
811-
812- int git_openssl__set_cert_location (const char * file , const char * path )
813- {
814- GIT_UNUSED (file );
815- GIT_UNUSED (path );
816-
817- giterr_set (GITERR_SSL , "openssl is not supported in this version" );
818- return -1 ;
819- }
820-
821802#endif
Original file line number Diff line number Diff line change 1313
1414extern int git_openssl_stream_global_init (void );
1515
16+ #ifdef GIT_OPENSSL
17+ extern int git_openssl__set_cert_location (const char * file , const char * path );
18+
1619extern int git_openssl_stream_new (git_stream * * out , const char * host , const char * port );
1720extern int git_openssl_stream_wrap (git_stream * * out , git_stream * in , const char * host );
18-
19- extern int git_openssl__set_cert_location (const char * file , const char * path );
21+ #endif
2022
2123#endif
Original file line number Diff line number Diff line change 1111
1212#include "git2/sys/stream.h"
1313
14+ #ifdef GIT_SECURE_TRANSPORT
15+
1416extern int git_stransport_stream_new (git_stream * * out , const char * host , const char * port );
1517extern int git_stransport_stream_wrap (git_stream * * out , git_stream * in , const char * host );
1618
1719#endif
20+
21+ #endif
You can’t perform that action at this time.
0 commit comments