diff options
author | Valery Piashchynski <[email protected]> | 2021-11-25 15:31:24 +0300 |
---|---|---|
committer | Valery Piashchynski <[email protected]> | 2021-11-25 15:31:24 +0300 |
commit | 6123a45bd77f50b137d46577089b7b43c692b2d1 (patch) | |
tree | fb688befd82ada5ee8fa466f3393b9db37b09538 /worker | |
parent | 6c5e3ab6c01d31caa2d14930c188bae697c5cd48 (diff) |
update goridge
print bad header in the error message
Signed-off-by: Valery Piashchynski <[email protected]>
Diffstat (limited to 'worker')
-rwxr-xr-x | worker/sync_worker.go | 6 | ||||
-rwxr-xr-x | worker/sync_worker_test.go | 2 | ||||
-rwxr-xr-x | worker/worker.go | 2 |
3 files changed, 3 insertions, 7 deletions
diff --git a/worker/sync_worker.go b/worker/sync_worker.go index deea8cb1..12937eac 100755 --- a/worker/sync_worker.go +++ b/worker/sync_worker.go @@ -190,11 +190,7 @@ func (tw *SyncWorkerImpl) execPayload(p *payload.Payload) (*payload.Payload, err return nil, errors.E(op, errors.Network, err) } if frameR == nil { - return nil, errors.E(op, errors.Network, errors.Str("nil fr received")) - } - - if !frameR.VerifyCRC(frameR.Header()) { - return nil, errors.E(op, errors.Network, errors.Str("failed to verify CRC")) + return nil, errors.E(op, errors.Network, errors.Str("nil frame received")) } flags := frameR.ReadFlags() diff --git a/worker/sync_worker_test.go b/worker/sync_worker_test.go index 41c0c92b..288cbd45 100755 --- a/worker/sync_worker_test.go +++ b/worker/sync_worker_test.go @@ -14,7 +14,7 @@ func Test_NotStarted_String(t *testing.T) { w, _ := InitBaseWorker(cmd) assert.Contains(t, w.String(), "php tests/client.php echo pipes") assert.Contains(t, w.String(), "inactive") - assert.Contains(t, w.String(), "numExecs: 0") + assert.Contains(t, w.String(), "num_execs: 0") } func Test_NotStarted_Exec(t *testing.T) { diff --git a/worker/worker.go b/worker/worker.go index 05c6dd0d..e5c3a192 100755 --- a/worker/worker.go +++ b/worker/worker.go @@ -111,7 +111,7 @@ func (w *Process) String() string { } return fmt.Sprintf( - "(`%s` [%s], numExecs: %v)", + "(`%s` [%s], num_execs: %v)", strings.Join(w.cmd.Args, " "), st, w.state.NumExecs(), |