1
0
mirror of https://github.com/docker/docker-credential-helpers.git synced 2026-06-13 16:01:28 +05:30

Merge pull request #191 from QiWang19/list-error

List wraps the error from secretservice_linux.c.
This commit is contained in:
Emmanuel Briney
2021-08-31 11:53:41 +02:00
committed by GitHub
+2 -1
View File
@@ -96,7 +96,8 @@ func (h Secretservice) List() (map[string]string, error) {
defer C.freeListData(&acctsC, listLenC)
if err != nil {
defer C.g_error_free(err)
return nil, errors.New("Error from list function in secretservice_linux.c likely due to error in secretservice library")
errMsg := (*C.char)(unsafe.Pointer(err.message))
return errors.New(C.GoString(errMsg))
}
resp := make(map[string]string)