Skip to content

Commit

Permalink
fix: add missing UnknownNetworkError
Browse files Browse the repository at this point in the history
  • Loading branch information
elewis787 committed Jul 11, 2024
1 parent 001ceab commit 8495d68
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions net.go
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,12 @@ type Listener interface {
Addr() Addr
}

type UnknownNetworkError string

func (e UnknownNetworkError) Error() string { return "unknown network " + string(e) }
func (e UnknownNetworkError) Timeout() bool { return false }
func (e UnknownNetworkError) Temporary() bool { return false }

// An Error represents a network error.
type Error interface {
error
Expand Down

0 comments on commit 8495d68

Please sign in to comment.