Skip to content

Commit 828f6eb

Browse files
committed
Fix a bug in shim log on Windows that can cause 100% CPU utilization
With the change to unified shims (ie: 1 shim per multiple tasks) the shimLog on Windows for the 2nd-Nth worload containers will not have an associated named pipe listener. Due to a subtle bug in errors.Wrap passing a nil error we would unblock the disconnected listener and return 0 byte successfull reads which would cause go to continually read and cap the CPU. Signed-off-by: Justin Terry (VM) <[email protected]>
1 parent e72ad44 commit 828f6eb

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

runtime/v2/shim_windows.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ func openShimLog(ctx context.Context, bundle *Bundle) (io.ReadCloser, error) {
7878
time.Second*10,
7979
)
8080
if conerr != nil {
81-
dpc.conerr = errors.Wrap(err, "failed to connect to shim log")
81+
dpc.conerr = errors.Wrap(conerr, "failed to connect to shim log")
8282
}
8383
dpc.c = c
8484
dpc.wg.Done()

0 commit comments

Comments
 (0)