summaryrefslogtreecommitdiff
path: root/credentials.go
diff options
context:
space:
mode:
authorlhchavez <[email protected]>2020-02-23 14:49:04 +0000
committerlhchavez <[email protected]>2020-02-23 14:49:04 +0000
commit627447092fa24035ed3cd4cf31932dbef6f5a57f (patch)
tree48a9122be45522cf1ec72535cec18fd701db55d2 /credentials.go
parent03339f731aba66baacab3fd67e7b2d185cdacb33 (diff)
parent06764f48dce903bf95701c6ef75ad0fe46c0dedf (diff)
Merge remote-tracking branch 'upstream/master' into more-annotated-commit
Diffstat (limited to 'credentials.go')
-rw-r--r--credentials.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/credentials.go b/credentials.go
index 4e42b6e..038313b 100644
--- a/credentials.go
+++ b/credentials.go
@@ -2,6 +2,9 @@ package git
/*
#include <git2.h>
+#include <git2/sys/cred.h>
+
+git_credtype_t _go_git_cred_credtype(git_cred *cred);
*/
import "C"
import "unsafe"
@@ -27,7 +30,7 @@ func (o *Cred) HasUsername() bool {
}
func (o *Cred) Type() CredType {
- return (CredType)(o.ptr.credtype)
+ return (CredType)(C._go_git_cred_credtype(o.ptr))
}
func credFromC(ptr *C.git_cred) *Cred {