routing+discovery: uniform error codes in routing

This commit is contained in:
yyforyongyu committed 2022-01-05 04:27:33 +08:00
1 parent c15c8a1f0b
commit dd74486b59
5 files changed
+45 -32

No files matched your search

+9 -3
View File
@@ -1062,13 +1062,19 @@ func (r *ChannelRouter) networkHandler() {
update.msg,
)
if err != nil {
switch err {
case ErrVBarrierShuttingDown:
switch {
case IsError(
err, ErrVBarrierShuttingDown,
):
update.err <- err
case ErrParentValidationFailed:
case IsError(
err, ErrParentValidationFailed,
):
update.err <- newErrf(
ErrIgnored, err.Error(),
)
default:
log.Warnf("unexpected error "+
"during validation "+