(pipe *syncSocket, expected syncType)
| 159 | } |
| 160 | |
| 161 | func readSyncFull(pipe *syncSocket, expected syncType) (syncT, error) { |
| 162 | sync, err := doReadSync(pipe) |
| 163 | if err != nil { |
| 164 | return sync, err |
| 165 | } |
| 166 | if sync.Type != expected { |
| 167 | return sync, fmt.Errorf("unexpected synchronisation flag: got %q, expected %q", sync.Type, expected) |
| 168 | } |
| 169 | return sync, nil |
| 170 | } |
| 171 | |
| 172 | func readSync(pipe *syncSocket, expected syncType) error { |
| 173 | sync, err := readSyncFull(pipe, expected) |
no test coverage detected
searching dependent graphs…