mirror of https://github.com/status-im/consul.git
26 lines
331 B
Go
26 lines
331 B
Go
package frame
|
|
|
|
import (
|
|
"fmt"
|
|
)
|
|
|
|
const (
|
|
NoError = iota
|
|
ProtocolError
|
|
InternalError
|
|
FlowControlError
|
|
StreamClosed
|
|
FrameSizeError
|
|
RefusedStream
|
|
Cancel
|
|
NoSuchError
|
|
)
|
|
|
|
type FramingError struct {
|
|
error
|
|
}
|
|
|
|
func protoError(fmtstr string, args ...interface{}) FramingError {
|
|
return FramingError{fmt.Errorf(fmtstr, args...)}
|
|
}
|