-
Notifications
You must be signed in to change notification settings - Fork 968
Closed
Description
Environment
- Server:
- Client:
- Protocol:
- Registry:
Issue description
code 1
https://github.com/apache/dubbo-go/blob/main/config/tls_config.go#L88
caBytes, err := os.ReadFile(opt.CACertFile)
if err != nil {
return nil, err
}
if ok := ca.AppendCertsFromPEM(caBytes); !ok {
return nil, err
}
the err is nil in line 88, here should define an error to return
code 2
https://github.com/apache/dubbo-go/blob/main/protocol/triple/internal/client/common/client.go#L68
https://github.com/apache/dubbo-go/blob/main/protocol/triple/internal/client/common/client.go#L92
if sendErr := stream.Send(&greet.GreetStreamRequest{Name: "triple"}); sendErr != nil {
return err
}
should return sendErr
but return a nil value err
I create a linter to detect code that returns a non-relevant nilness error bug. I checked the top 1000 GitHub Go repositories and found this, all result listed in alingse/sundrylint#4
Logs
Click me to check logs
Copy logs to here.
No-SilverBullet
Metadata
Metadata
Assignees
Labels
No labels