use shimCtx for fifo copy

Signed-off-by: yylt <yang8518296@163.com>
This commit is contained in:
yylt 2025-03-04 16:15:14 +08:00 committed by k8s-infra-cherrypick-robot
parent a5b872b5c8
commit e04543db09

View File

@ -91,9 +91,9 @@ func loadShim(ctx context.Context, bundle *Bundle, onClose func()) (_ ShimInstan
// To prevent flood of error messages, the expected error // To prevent flood of error messages, the expected error
// should be reset, like os.ErrClosed or os.ErrNotExist, which // should be reset, like os.ErrClosed or os.ErrNotExist, which
// depends on platform. // depends on platform.
err = checkCopyShimLogError(ctx, err) err = checkCopyShimLogError(shimCtx, err)
if err != nil { if err != nil {
log.G(ctx).WithError(err).Error("copy shim log after reload") log.G(shimCtx).WithError(err).Error("copy shim log after reload")
} }
}() }()
onCloseWithShimLog := func() { onCloseWithShimLog := func() {