Merge pull request #100 from tklauser/ucred-wrap-err
Wrap correct error on unix.GetsockoptUcred failure
This commit is contained in:
commit
332f4c9a9b
@ -50,7 +50,7 @@ func (fn UnixCredentialsFunc) Handshake(_ context.Context, conn net.Conn) (net.C
|
||||
}
|
||||
|
||||
if ucredErr != nil {
|
||||
return nil, nil, fmt.Errorf("ttrpc.UnixCredentialsFunc: failed to retrieve socket peer credentials: %w", err)
|
||||
return nil, nil, fmt.Errorf("ttrpc.UnixCredentialsFunc: failed to retrieve socket peer credentials: %w", ucredErr)
|
||||
}
|
||||
|
||||
if err := fn(ucred); err != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user