go.mod github.com/Microsoft/hcsshim v0.8.16

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn
2021-03-12 17:17:51 +01:00
parent bc856372bb
commit 75b64e0f60
623 changed files with 60114 additions and 6182 deletions

View File

@ -4,9 +4,10 @@ package wclayer
// functionality.
import (
"context"
"syscall"
"github.com/Microsoft/hcsshim/internal/guid"
"github.com/Microsoft/go-winio/pkg/guid"
"github.com/sirupsen/logrus"
)
@ -68,12 +69,12 @@ type WC_LAYER_DESCRIPTOR struct {
Pathp *uint16
}
func layerPathsToDescriptors(parentLayerPaths []string) ([]WC_LAYER_DESCRIPTOR, error) {
func layerPathsToDescriptors(ctx context.Context, parentLayerPaths []string) ([]WC_LAYER_DESCRIPTOR, error) {
// Array of descriptors that gets constructed.
var layers []WC_LAYER_DESCRIPTOR
for i := 0; i < len(parentLayerPaths); i++ {
g, err := LayerID(parentLayerPaths[i])
g, err := LayerID(ctx, parentLayerPaths[i])
if err != nil {
logrus.WithError(err).Debug("Failed to convert name to guid")
return nil, err