mirror of
https://github.com/containers/skopeo.git
synced 2025-06-30 08:32:21 +00:00
Merge pull request #344 from mtrmac/storage-rebase
Pull in rhatdan/image:master
This commit is contained in:
commit
e1884aa8a8
@ -44,4 +44,4 @@ github.com/mistifyio/go-zfs 22c9b32c84eb0d0c6f4043b6e90fc94073de92fa
|
|||||||
github.com/pborman/uuid v1.0
|
github.com/pborman/uuid v1.0
|
||||||
github.com/opencontainers/selinux master
|
github.com/opencontainers/selinux master
|
||||||
golang.org/x/sys/unix master
|
golang.org/x/sys/unix master
|
||||||
github.com/tchap/go-patricia master
|
github.com/tchap/go-patricia v2.2.6
|
||||||
|
18
vendor/github.com/containers/image/storage/storage_image.go
generated
vendored
18
vendor/github.com/containers/image/storage/storage_image.go
generated
vendored
@ -13,9 +13,9 @@ import (
|
|||||||
"github.com/containers/image/image"
|
"github.com/containers/image/image"
|
||||||
"github.com/containers/image/manifest"
|
"github.com/containers/image/manifest"
|
||||||
"github.com/containers/image/types"
|
"github.com/containers/image/types"
|
||||||
|
"github.com/containers/storage"
|
||||||
"github.com/containers/storage/pkg/archive"
|
"github.com/containers/storage/pkg/archive"
|
||||||
"github.com/containers/storage/pkg/ioutils"
|
"github.com/containers/storage/pkg/ioutils"
|
||||||
"github.com/containers/storage/storage"
|
|
||||||
ddigest "github.com/opencontainers/go-digest"
|
ddigest "github.com/opencontainers/go-digest"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -307,7 +307,7 @@ func (s *storageImageDestination) ReapplyBlob(blobinfo types.BlobInfo) (types.Bl
|
|||||||
return types.BlobInfo{}, err
|
return types.BlobInfo{}, err
|
||||||
}
|
}
|
||||||
if layerList, ok := s.Layers[blobinfo.Digest]; !ok || len(layerList) < 1 {
|
if layerList, ok := s.Layers[blobinfo.Digest]; !ok || len(layerList) < 1 {
|
||||||
b, err := s.imageRef.transport.store.GetImageBigData(s.ID, blobinfo.Digest.String())
|
b, err := s.imageRef.transport.store.ImageBigData(s.ID, blobinfo.Digest.String())
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return types.BlobInfo{}, err
|
return types.BlobInfo{}, err
|
||||||
}
|
}
|
||||||
@ -335,7 +335,7 @@ func (s *storageImageDestination) Commit() error {
|
|||||||
logrus.Debugf("error creating image: %q", err)
|
logrus.Debugf("error creating image: %q", err)
|
||||||
return errors.Wrapf(err, "error creating image %q", s.ID)
|
return errors.Wrapf(err, "error creating image %q", s.ID)
|
||||||
}
|
}
|
||||||
img, err = s.imageRef.transport.store.GetImage(s.ID)
|
img, err = s.imageRef.transport.store.Image(s.ID)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return errors.Wrapf(err, "error reading image %q", s.ID)
|
return errors.Wrapf(err, "error reading image %q", s.ID)
|
||||||
}
|
}
|
||||||
@ -468,7 +468,7 @@ func (s *storageImageSource) getBlobAndLayerID(info types.BlobInfo) (rc io.ReadC
|
|||||||
return nil, -1, "", err
|
return nil, -1, "", err
|
||||||
}
|
}
|
||||||
if layerList, ok := s.Layers[info.Digest]; !ok || len(layerList) < 1 {
|
if layerList, ok := s.Layers[info.Digest]; !ok || len(layerList) < 1 {
|
||||||
b, err := s.imageRef.transport.store.GetImageBigData(s.ID, info.Digest.String())
|
b, err := s.imageRef.transport.store.ImageBigData(s.ID, info.Digest.String())
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, -1, "", err
|
return nil, -1, "", err
|
||||||
}
|
}
|
||||||
@ -492,7 +492,7 @@ func (s *storageImageSource) getBlobAndLayerID(info types.BlobInfo) (rc io.ReadC
|
|||||||
}
|
}
|
||||||
|
|
||||||
func diffLayer(store storage.Store, layerID string) (rc io.ReadCloser, n int64, err error) {
|
func diffLayer(store storage.Store, layerID string) (rc io.ReadCloser, n int64, err error) {
|
||||||
layer, err := store.GetLayer(layerID)
|
layer, err := store.Layer(layerID)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, -1, err
|
return nil, -1, err
|
||||||
}
|
}
|
||||||
@ -517,7 +517,7 @@ func diffLayer(store storage.Store, layerID string) (rc io.ReadCloser, n int64,
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (s *storageImageSource) GetManifest() (manifestBlob []byte, MIMEType string, err error) {
|
func (s *storageImageSource) GetManifest() (manifestBlob []byte, MIMEType string, err error) {
|
||||||
manifestBlob, err = s.imageRef.transport.store.GetImageBigData(s.ID, "manifest")
|
manifestBlob, err = s.imageRef.transport.store.ImageBigData(s.ID, "manifest")
|
||||||
return manifestBlob, manifest.GuessMIMEType(manifestBlob), err
|
return manifestBlob, manifest.GuessMIMEType(manifestBlob), err
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -527,7 +527,7 @@ func (s *storageImageSource) GetTargetManifest(digest ddigest.Digest) (manifestB
|
|||||||
|
|
||||||
func (s *storageImageSource) GetSignatures() (signatures [][]byte, err error) {
|
func (s *storageImageSource) GetSignatures() (signatures [][]byte, err error) {
|
||||||
var offset int
|
var offset int
|
||||||
signature, err := s.imageRef.transport.store.GetImageBigData(s.ID, "signatures")
|
signature, err := s.imageRef.transport.store.ImageBigData(s.ID, "signatures")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@ -549,7 +549,7 @@ func (s *storageImageSource) getSize() (int64, error) {
|
|||||||
return -1, errors.Wrapf(err, "error reading image %q", s.imageRef.id)
|
return -1, errors.Wrapf(err, "error reading image %q", s.imageRef.id)
|
||||||
}
|
}
|
||||||
for _, name := range names {
|
for _, name := range names {
|
||||||
bigSize, err := s.imageRef.transport.store.GetImageBigDataSize(s.imageRef.id, name)
|
bigSize, err := s.imageRef.transport.store.ImageBigDataSize(s.imageRef.id, name)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return -1, errors.Wrapf(err, "error reading data blob size %q for %q", name, s.imageRef.id)
|
return -1, errors.Wrapf(err, "error reading data blob size %q for %q", name, s.imageRef.id)
|
||||||
}
|
}
|
||||||
@ -560,7 +560,7 @@ func (s *storageImageSource) getSize() (int64, error) {
|
|||||||
}
|
}
|
||||||
for _, layerList := range s.Layers {
|
for _, layerList := range s.Layers {
|
||||||
for _, layerID := range layerList {
|
for _, layerID := range layerList {
|
||||||
layer, err := s.imageRef.transport.store.GetLayer(layerID)
|
layer, err := s.imageRef.transport.store.Layer(layerID)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return -1, err
|
return -1, err
|
||||||
}
|
}
|
||||||
|
12
vendor/github.com/containers/image/storage/storage_reference.go
generated
vendored
12
vendor/github.com/containers/image/storage/storage_reference.go
generated
vendored
@ -6,7 +6,7 @@ import (
|
|||||||
"github.com/Sirupsen/logrus"
|
"github.com/Sirupsen/logrus"
|
||||||
"github.com/containers/image/docker/reference"
|
"github.com/containers/image/docker/reference"
|
||||||
"github.com/containers/image/types"
|
"github.com/containers/image/types"
|
||||||
"github.com/containers/storage/storage"
|
"github.com/containers/storage"
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -37,7 +37,7 @@ func newReference(transport storageTransport, reference, id string, name referen
|
|||||||
// one present with the same name or ID, and return the image.
|
// one present with the same name or ID, and return the image.
|
||||||
func (s *storageReference) resolveImage() (*storage.Image, error) {
|
func (s *storageReference) resolveImage() (*storage.Image, error) {
|
||||||
if s.id == "" {
|
if s.id == "" {
|
||||||
image, err := s.transport.store.GetImage(s.reference)
|
image, err := s.transport.store.Image(s.reference)
|
||||||
if image != nil && err == nil {
|
if image != nil && err == nil {
|
||||||
s.id = image.ID
|
s.id = image.ID
|
||||||
}
|
}
|
||||||
@ -46,7 +46,7 @@ func (s *storageReference) resolveImage() (*storage.Image, error) {
|
|||||||
logrus.Errorf("reference %q does not resolve to an image ID", s.StringWithinTransport())
|
logrus.Errorf("reference %q does not resolve to an image ID", s.StringWithinTransport())
|
||||||
return nil, ErrNoSuchImage
|
return nil, ErrNoSuchImage
|
||||||
}
|
}
|
||||||
img, err := s.transport.store.GetImage(s.id)
|
img, err := s.transport.store.Image(s.id)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, errors.Wrapf(err, "error reading image %q", s.id)
|
return nil, errors.Wrapf(err, "error reading image %q", s.id)
|
||||||
}
|
}
|
||||||
@ -83,7 +83,7 @@ func (s storageReference) DockerReference() reference.Named {
|
|||||||
// disambiguate between images which may be present in multiple stores and
|
// disambiguate between images which may be present in multiple stores and
|
||||||
// share only their names.
|
// share only their names.
|
||||||
func (s storageReference) StringWithinTransport() string {
|
func (s storageReference) StringWithinTransport() string {
|
||||||
storeSpec := "[" + s.transport.store.GetGraphDriverName() + "@" + s.transport.store.GetGraphRoot() + "]"
|
storeSpec := "[" + s.transport.store.GraphDriverName() + "@" + s.transport.store.GraphRoot() + "]"
|
||||||
if s.name == nil {
|
if s.name == nil {
|
||||||
return storeSpec + "@" + s.id
|
return storeSpec + "@" + s.id
|
||||||
}
|
}
|
||||||
@ -102,8 +102,8 @@ func (s storageReference) PolicyConfigurationIdentity() string {
|
|||||||
// graph root, in case we're using multiple drivers in the same directory for
|
// graph root, in case we're using multiple drivers in the same directory for
|
||||||
// some reason.
|
// some reason.
|
||||||
func (s storageReference) PolicyConfigurationNamespaces() []string {
|
func (s storageReference) PolicyConfigurationNamespaces() []string {
|
||||||
storeSpec := "[" + s.transport.store.GetGraphDriverName() + "@" + s.transport.store.GetGraphRoot() + "]"
|
storeSpec := "[" + s.transport.store.GraphDriverName() + "@" + s.transport.store.GraphRoot() + "]"
|
||||||
driverlessStoreSpec := "[" + s.transport.store.GetGraphRoot() + "]"
|
driverlessStoreSpec := "[" + s.transport.store.GraphRoot() + "]"
|
||||||
namespaces := []string{}
|
namespaces := []string{}
|
||||||
if s.name != nil {
|
if s.name != nil {
|
||||||
if s.id != "" {
|
if s.id != "" {
|
||||||
|
8
vendor/github.com/containers/image/storage/storage_transport.go
generated
vendored
8
vendor/github.com/containers/image/storage/storage_transport.go
generated
vendored
@ -10,7 +10,7 @@ import (
|
|||||||
"github.com/containers/image/docker/reference"
|
"github.com/containers/image/docker/reference"
|
||||||
"github.com/containers/image/transports"
|
"github.com/containers/image/transports"
|
||||||
"github.com/containers/image/types"
|
"github.com/containers/image/types"
|
||||||
"github.com/containers/storage/storage"
|
"github.com/containers/storage"
|
||||||
"github.com/opencontainers/go-digest"
|
"github.com/opencontainers/go-digest"
|
||||||
ddigest "github.com/opencontainers/go-digest"
|
ddigest "github.com/opencontainers/go-digest"
|
||||||
)
|
)
|
||||||
@ -110,7 +110,7 @@ func (s storageTransport) ParseStoreReference(store storage.Store, ref string) (
|
|||||||
// recognize.
|
// recognize.
|
||||||
return nil, ErrInvalidReference
|
return nil, ErrInvalidReference
|
||||||
}
|
}
|
||||||
storeSpec := "[" + store.GetGraphDriverName() + "@" + store.GetGraphRoot() + "]"
|
storeSpec := "[" + store.GraphDriverName() + "@" + store.GraphRoot() + "]"
|
||||||
id := ""
|
id := ""
|
||||||
if sum.Validate() == nil {
|
if sum.Validate() == nil {
|
||||||
id = sum.Hex()
|
id = sum.Hex()
|
||||||
@ -205,14 +205,14 @@ func (s storageTransport) GetStoreImage(store storage.Store, ref types.ImageRefe
|
|||||||
if dref == nil {
|
if dref == nil {
|
||||||
if sref, ok := ref.(*storageReference); ok {
|
if sref, ok := ref.(*storageReference); ok {
|
||||||
if sref.id != "" {
|
if sref.id != "" {
|
||||||
if img, err := store.GetImage(sref.id); err == nil {
|
if img, err := store.Image(sref.id); err == nil {
|
||||||
return img, nil
|
return img, nil
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return nil, ErrInvalidReference
|
return nil, ErrInvalidReference
|
||||||
}
|
}
|
||||||
return store.GetImage(verboseName(dref))
|
return store.Image(verboseName(dref))
|
||||||
}
|
}
|
||||||
|
|
||||||
func (s *storageTransport) GetImage(ref types.ImageReference) (*storage.Image, error) {
|
func (s *storageTransport) GetImage(ref types.ImageReference) (*storage.Image, error) {
|
||||||
|
@ -264,7 +264,7 @@ func (r *containerStore) Create(id string, names []string, image, layer, metadat
|
|||||||
return container, err
|
return container, err
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *containerStore) GetMetadata(id string) (string, error) {
|
func (r *containerStore) Metadata(id string) (string, error) {
|
||||||
if container, ok := r.lookup(id); ok {
|
if container, ok := r.lookup(id); ok {
|
||||||
return container.Metadata, nil
|
return container.Metadata, nil
|
||||||
}
|
}
|
||||||
@ -347,7 +347,7 @@ func (r *containerStore) Exists(id string) bool {
|
|||||||
return ok
|
return ok
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *containerStore) GetBigData(id, key string) ([]byte, error) {
|
func (r *containerStore) BigData(id, key string) ([]byte, error) {
|
||||||
c, ok := r.lookup(id)
|
c, ok := r.lookup(id)
|
||||||
if !ok {
|
if !ok {
|
||||||
return nil, ErrContainerUnknown
|
return nil, ErrContainerUnknown
|
||||||
@ -355,7 +355,7 @@ func (r *containerStore) GetBigData(id, key string) ([]byte, error) {
|
|||||||
return ioutil.ReadFile(r.datapath(c.ID, key))
|
return ioutil.ReadFile(r.datapath(c.ID, key))
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *containerStore) GetBigDataSize(id, key string) (int64, error) {
|
func (r *containerStore) BigDataSize(id, key string) (int64, error) {
|
||||||
c, ok := r.lookup(id)
|
c, ok := r.lookup(id)
|
||||||
if !ok {
|
if !ok {
|
||||||
return -1, ErrContainerUnknown
|
return -1, ErrContainerUnknown
|
||||||
@ -366,7 +366,7 @@ func (r *containerStore) GetBigDataSize(id, key string) (int64, error) {
|
|||||||
return -1, ErrSizeUnknown
|
return -1, ErrSizeUnknown
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *containerStore) GetBigDataNames(id string) ([]string, error) {
|
func (r *containerStore) BigDataNames(id string) ([]string, error) {
|
||||||
c, ok := r.lookup(id)
|
c, ok := r.lookup(id)
|
||||||
if !ok {
|
if !ok {
|
||||||
return nil, ErrContainerUnknown
|
return nil, ErrContainerUnknown
|
4
vendor/github.com/containers/storage/drivers/aufs/aufs.go
generated
vendored
4
vendor/github.com/containers/storage/drivers/aufs/aufs.go
generated
vendored
@ -185,8 +185,8 @@ func (a *Driver) Status() [][2]string {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetMetadata not implemented
|
// Metadata not implemented
|
||||||
func (a *Driver) GetMetadata(id string) (map[string]string, error) {
|
func (a *Driver) Metadata(id string) (map[string]string, error) {
|
||||||
return nil, nil
|
return nil, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
4
vendor/github.com/containers/storage/drivers/btrfs/btrfs.go
generated
vendored
4
vendor/github.com/containers/storage/drivers/btrfs/btrfs.go
generated
vendored
@ -143,8 +143,8 @@ func (d *Driver) Status() [][2]string {
|
|||||||
return status
|
return status
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetMetadata returns empty metadata for this driver.
|
// Metadata returns empty metadata for this driver.
|
||||||
func (d *Driver) GetMetadata(id string) (map[string]string, error) {
|
func (d *Driver) Metadata(id string) (map[string]string, error) {
|
||||||
return nil, nil
|
return nil, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
4
vendor/github.com/containers/storage/drivers/devmapper/driver.go
generated
vendored
4
vendor/github.com/containers/storage/drivers/devmapper/driver.go
generated
vendored
@ -94,8 +94,8 @@ func (d *Driver) Status() [][2]string {
|
|||||||
return status
|
return status
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetMetadata returns a map of information about the device.
|
// Metadata returns a map of information about the device.
|
||||||
func (d *Driver) GetMetadata(id string) (map[string]string, error) {
|
func (d *Driver) Metadata(id string) (map[string]string, error) {
|
||||||
m, err := d.DeviceSet.exportDeviceMetadata(id)
|
m, err := d.DeviceSet.exportDeviceMetadata(id)
|
||||||
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
2
vendor/github.com/containers/storage/drivers/driver.go
generated
vendored
2
vendor/github.com/containers/storage/drivers/driver.go
generated
vendored
@ -69,7 +69,7 @@ type ProtoDriver interface {
|
|||||||
Status() [][2]string
|
Status() [][2]string
|
||||||
// Returns a set of key-value pairs which give low level information
|
// Returns a set of key-value pairs which give low level information
|
||||||
// about the image/container driver is managing.
|
// about the image/container driver is managing.
|
||||||
GetMetadata(id string) (map[string]string, error)
|
Metadata(id string) (map[string]string, error)
|
||||||
// Cleanup performs necessary tasks to release resources
|
// Cleanup performs necessary tasks to release resources
|
||||||
// held by the driver, e.g., unmounting all layered filesystems
|
// held by the driver, e.g., unmounting all layered filesystems
|
||||||
// known to this driver.
|
// known to this driver.
|
||||||
|
4
vendor/github.com/containers/storage/drivers/overlay/overlay.go
generated
vendored
4
vendor/github.com/containers/storage/drivers/overlay/overlay.go
generated
vendored
@ -226,9 +226,9 @@ func (d *Driver) Status() [][2]string {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetMetadata returns meta data about the overlay driver such as
|
// Metadata returns meta data about the overlay driver such as
|
||||||
// LowerDir, UpperDir, WorkDir and MergeDir used to store data.
|
// LowerDir, UpperDir, WorkDir and MergeDir used to store data.
|
||||||
func (d *Driver) GetMetadata(id string) (map[string]string, error) {
|
func (d *Driver) Metadata(id string) (map[string]string, error) {
|
||||||
dir := d.dir(id)
|
dir := d.dir(id)
|
||||||
if _, err := os.Stat(dir); err != nil {
|
if _, err := os.Stat(dir); err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
|
4
vendor/github.com/containers/storage/drivers/proxy.go
generated
vendored
4
vendor/github.com/containers/storage/drivers/proxy.go
generated
vendored
@ -144,12 +144,12 @@ func (d *graphDriverProxy) Status() [][2]string {
|
|||||||
return ret.Status
|
return ret.Status
|
||||||
}
|
}
|
||||||
|
|
||||||
func (d *graphDriverProxy) GetMetadata(id string) (map[string]string, error) {
|
func (d *graphDriverProxy) Metadata(id string) (map[string]string, error) {
|
||||||
args := &graphDriverRequest{
|
args := &graphDriverRequest{
|
||||||
ID: id,
|
ID: id,
|
||||||
}
|
}
|
||||||
var ret graphDriverResponse
|
var ret graphDriverResponse
|
||||||
if err := d.client.Call("GraphDriver.GetMetadata", args, &ret); err != nil {
|
if err := d.client.Call("GraphDriver.Metadata", args, &ret); err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
if ret.Err != "" {
|
if ret.Err != "" {
|
||||||
|
4
vendor/github.com/containers/storage/drivers/vfs/driver.go
generated
vendored
4
vendor/github.com/containers/storage/drivers/vfs/driver.go
generated
vendored
@ -58,8 +58,8 @@ func (d *Driver) Status() [][2]string {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetMetadata is used for implementing the graphdriver.ProtoDriver interface. VFS does not currently have any meta data.
|
// Metadata is used for implementing the graphdriver.ProtoDriver interface. VFS does not currently have any meta data.
|
||||||
func (d *Driver) GetMetadata(id string) (map[string]string, error) {
|
func (d *Driver) Metadata(id string) (map[string]string, error) {
|
||||||
return nil, nil
|
return nil, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
10
vendor/github.com/containers/storage/drivers/windows/windows.go
generated
vendored
10
vendor/github.com/containers/storage/drivers/windows/windows.go
generated
vendored
@ -133,7 +133,7 @@ func (d *Driver) create(id, parent, mountLabel string, readOnly bool, storageOpt
|
|||||||
var layerChain []string
|
var layerChain []string
|
||||||
|
|
||||||
if rPId != "" {
|
if rPId != "" {
|
||||||
parentPath, err := hcsshim.GetLayerMountPath(d.info, rPId)
|
parentPath, err := hcsshim.LayerMountPath(d.info, rPId)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
@ -248,7 +248,7 @@ func (d *Driver) Get(id, mountLabel string) (string, error) {
|
|||||||
return "", err
|
return "", err
|
||||||
}
|
}
|
||||||
|
|
||||||
mountPath, err := hcsshim.GetLayerMountPath(d.info, rID)
|
mountPath, err := hcsshim.LayerMountPath(d.info, rID)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
d.ctr.Decrement(rID)
|
d.ctr.Decrement(rID)
|
||||||
if err2 := hcsshim.DeactivateLayer(d.info, rID); err2 != nil {
|
if err2 := hcsshim.DeactivateLayer(d.info, rID); err2 != nil {
|
||||||
@ -403,7 +403,7 @@ func (d *Driver) ApplyDiff(id, parent string, diff archive.Reader) (int64, error
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return 0, err
|
return 0, err
|
||||||
}
|
}
|
||||||
parentPath, err := hcsshim.GetLayerMountPath(d.info, rPId)
|
parentPath, err := hcsshim.LayerMountPath(d.info, rPId)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return 0, err
|
return 0, err
|
||||||
}
|
}
|
||||||
@ -446,8 +446,8 @@ func (d *Driver) DiffSize(id, parent string) (size int64, err error) {
|
|||||||
return archive.ChangesSize(layerFs, changes), nil
|
return archive.ChangesSize(layerFs, changes), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetMetadata returns custom driver information.
|
// Metadata returns custom driver information.
|
||||||
func (d *Driver) GetMetadata(id string) (map[string]string, error) {
|
func (d *Driver) Metadata(id string) (map[string]string, error) {
|
||||||
m := make(map[string]string)
|
m := make(map[string]string)
|
||||||
m["dir"] = d.dir(id)
|
m["dir"] = d.dir(id)
|
||||||
return m, nil
|
return m, nil
|
||||||
|
4
vendor/github.com/containers/storage/drivers/zfs/zfs.go
generated
vendored
4
vendor/github.com/containers/storage/drivers/zfs/zfs.go
generated
vendored
@ -210,8 +210,8 @@ func (d *Driver) Status() [][2]string {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetMetadata returns image/container metadata related to graph driver
|
// Metadata returns image/container metadata related to graph driver
|
||||||
func (d *Driver) GetMetadata(id string) (map[string]string, error) {
|
func (d *Driver) Metadata(id string) (map[string]string, error) {
|
||||||
return nil, nil
|
return nil, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -249,7 +249,7 @@ func (r *imageStore) Create(id string, names []string, layer, metadata string) (
|
|||||||
return image, err
|
return image, err
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *imageStore) GetMetadata(id string) (string, error) {
|
func (r *imageStore) Metadata(id string) (string, error) {
|
||||||
if image, ok := r.lookup(id); ok {
|
if image, ok := r.lookup(id); ok {
|
||||||
return image.Metadata, nil
|
return image.Metadata, nil
|
||||||
}
|
}
|
||||||
@ -331,7 +331,7 @@ func (r *imageStore) Exists(id string) bool {
|
|||||||
return ok
|
return ok
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *imageStore) GetBigData(id, key string) ([]byte, error) {
|
func (r *imageStore) BigData(id, key string) ([]byte, error) {
|
||||||
image, ok := r.lookup(id)
|
image, ok := r.lookup(id)
|
||||||
if !ok {
|
if !ok {
|
||||||
return nil, ErrImageUnknown
|
return nil, ErrImageUnknown
|
||||||
@ -339,7 +339,7 @@ func (r *imageStore) GetBigData(id, key string) ([]byte, error) {
|
|||||||
return ioutil.ReadFile(r.datapath(image.ID, key))
|
return ioutil.ReadFile(r.datapath(image.ID, key))
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *imageStore) GetBigDataSize(id, key string) (int64, error) {
|
func (r *imageStore) BigDataSize(id, key string) (int64, error) {
|
||||||
image, ok := r.lookup(id)
|
image, ok := r.lookup(id)
|
||||||
if !ok {
|
if !ok {
|
||||||
return -1, ErrImageUnknown
|
return -1, ErrImageUnknown
|
||||||
@ -350,7 +350,7 @@ func (r *imageStore) GetBigDataSize(id, key string) (int64, error) {
|
|||||||
return -1, ErrSizeUnknown
|
return -1, ErrSizeUnknown
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *imageStore) GetBigDataNames(id string) ([]string, error) {
|
func (r *imageStore) BigDataNames(id string) ([]string, error) {
|
||||||
image, ok := r.lookup(id)
|
image, ok := r.lookup(id)
|
||||||
if !ok {
|
if !ok {
|
||||||
return nil, ErrImageUnknown
|
return nil, ErrImageUnknown
|
@ -163,7 +163,6 @@ type layerStore struct {
|
|||||||
idindex *truncindex.TruncIndex
|
idindex *truncindex.TruncIndex
|
||||||
byid map[string]*Layer
|
byid map[string]*Layer
|
||||||
byname map[string]*Layer
|
byname map[string]*Layer
|
||||||
byparent map[string][]*Layer
|
|
||||||
bymount map[string]*Layer
|
bymount map[string]*Layer
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -231,7 +230,6 @@ func (r *layerStore) Load() error {
|
|||||||
r.idindex = truncindex.NewTruncIndex(idlist)
|
r.idindex = truncindex.NewTruncIndex(idlist)
|
||||||
r.byid = ids
|
r.byid = ids
|
||||||
r.byname = names
|
r.byname = names
|
||||||
r.byparent = parents
|
|
||||||
r.bymount = mounts
|
r.bymount = mounts
|
||||||
err = nil
|
err = nil
|
||||||
// Last step: try to remove anything that a previous user of this
|
// Last step: try to remove anything that a previous user of this
|
||||||
@ -309,7 +307,6 @@ func newLayerStore(rundir string, layerdir string, driver drivers.Driver) (Layer
|
|||||||
byid: make(map[string]*Layer),
|
byid: make(map[string]*Layer),
|
||||||
bymount: make(map[string]*Layer),
|
bymount: make(map[string]*Layer),
|
||||||
byname: make(map[string]*Layer),
|
byname: make(map[string]*Layer),
|
||||||
byparent: make(map[string][]*Layer),
|
|
||||||
}
|
}
|
||||||
if err := rlstore.Load(); err != nil {
|
if err := rlstore.Load(); err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
@ -400,12 +397,6 @@ func (r *layerStore) Put(id, parent string, names []string, mountLabel string, o
|
|||||||
for _, name := range names {
|
for _, name := range names {
|
||||||
r.byname[name] = layer
|
r.byname[name] = layer
|
||||||
}
|
}
|
||||||
if pslice, ok := r.byparent[parent]; ok {
|
|
||||||
pslice = append(pslice, layer)
|
|
||||||
r.byparent[parent] = pslice
|
|
||||||
} else {
|
|
||||||
r.byparent[parent] = []*Layer{layer}
|
|
||||||
}
|
|
||||||
for flag, value := range flags {
|
for flag, value := range flags {
|
||||||
layer.Flags[flag] = value
|
layer.Flags[flag] = value
|
||||||
}
|
}
|
||||||
@ -520,7 +511,7 @@ func (r *layerStore) SetNames(id string, names []string) error {
|
|||||||
return ErrLayerUnknown
|
return ErrLayerUnknown
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *layerStore) GetMetadata(id string) (string, error) {
|
func (r *layerStore) Metadata(id string) (string, error) {
|
||||||
if layer, ok := r.lookup(id); ok {
|
if layer, ok := r.lookup(id); ok {
|
||||||
return layer.Metadata, nil
|
return layer.Metadata, nil
|
||||||
}
|
}
|
||||||
@ -553,23 +544,8 @@ func (r *layerStore) Delete(id string) error {
|
|||||||
err := r.driver.Remove(id)
|
err := r.driver.Remove(id)
|
||||||
if err == nil {
|
if err == nil {
|
||||||
os.Remove(r.tspath(id))
|
os.Remove(r.tspath(id))
|
||||||
pslice := r.byparent[layer.Parent]
|
|
||||||
newPslice := []*Layer{}
|
|
||||||
for _, candidate := range pslice {
|
|
||||||
if candidate.ID != id {
|
|
||||||
newPslice = append(newPslice, candidate)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
delete(r.byid, id)
|
delete(r.byid, id)
|
||||||
r.idindex.Delete(id)
|
r.idindex.Delete(id)
|
||||||
if len(newPslice) > 0 {
|
|
||||||
r.byparent[layer.Parent] = newPslice
|
|
||||||
} else {
|
|
||||||
delete(r.byparent, layer.Parent)
|
|
||||||
}
|
|
||||||
for _, name := range layer.Names {
|
|
||||||
delete(r.byname, name)
|
|
||||||
}
|
|
||||||
if layer.MountPoint != "" {
|
if layer.MountPoint != "" {
|
||||||
delete(r.bymount, layer.MountPoint)
|
delete(r.bymount, layer.MountPoint)
|
||||||
}
|
}
|
||||||
@ -619,11 +595,12 @@ func (r *layerStore) Wipe() error {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *layerStore) findParentAndLayer(from, to string) (fromID string, toID string, fromLayer *Layer, toLayer *Layer, err error) {
|
func (r *layerStore) findParentAndLayer(from, to string) (fromID string, toID string, toLayer *Layer, err error) {
|
||||||
var ok bool
|
var ok bool
|
||||||
|
var fromLayer *Layer
|
||||||
toLayer, ok = r.lookup(to)
|
toLayer, ok = r.lookup(to)
|
||||||
if !ok {
|
if !ok {
|
||||||
return "", "", nil, nil, ErrLayerUnknown
|
return "", "", nil, ErrLayerUnknown
|
||||||
}
|
}
|
||||||
to = toLayer.ID
|
to = toLayer.ID
|
||||||
if from == "" {
|
if from == "" {
|
||||||
@ -631,19 +608,20 @@ func (r *layerStore) findParentAndLayer(from, to string) (fromID string, toID st
|
|||||||
}
|
}
|
||||||
if from != "" {
|
if from != "" {
|
||||||
fromLayer, ok = r.lookup(from)
|
fromLayer, ok = r.lookup(from)
|
||||||
if !ok {
|
if ok {
|
||||||
|
from = fromLayer.ID
|
||||||
|
} else {
|
||||||
fromLayer, ok = r.lookup(toLayer.Parent)
|
fromLayer, ok = r.lookup(toLayer.Parent)
|
||||||
if !ok {
|
if ok {
|
||||||
return "", "", nil, nil, ErrParentUnknown
|
|
||||||
}
|
|
||||||
}
|
|
||||||
from = fromLayer.ID
|
from = fromLayer.ID
|
||||||
}
|
}
|
||||||
return from, to, fromLayer, toLayer, nil
|
}
|
||||||
|
}
|
||||||
|
return from, to, toLayer, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *layerStore) Changes(from, to string) ([]archive.Change, error) {
|
func (r *layerStore) Changes(from, to string) ([]archive.Change, error) {
|
||||||
from, to, _, _, err := r.findParentAndLayer(from, to)
|
from, to, _, err := r.findParentAndLayer(from, to)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, ErrLayerUnknown
|
return nil, ErrLayerUnknown
|
||||||
}
|
}
|
||||||
@ -682,7 +660,7 @@ func (r *layerStore) newFileGetter(id string) (drivers.FileGetCloser, error) {
|
|||||||
func (r *layerStore) Diff(from, to string) (io.ReadCloser, error) {
|
func (r *layerStore) Diff(from, to string) (io.ReadCloser, error) {
|
||||||
var metadata storage.Unpacker
|
var metadata storage.Unpacker
|
||||||
|
|
||||||
from, to, _, toLayer, err := r.findParentAndLayer(from, to)
|
from, to, toLayer, err := r.findParentAndLayer(from, to)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, ErrLayerUnknown
|
return nil, ErrLayerUnknown
|
||||||
}
|
}
|
||||||
@ -772,7 +750,7 @@ func (r *layerStore) Diff(from, to string) (io.ReadCloser, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (r *layerStore) DiffSize(from, to string) (size int64, err error) {
|
func (r *layerStore) DiffSize(from, to string) (size int64, err error) {
|
||||||
from, to, _, _, err = r.findParentAndLayer(from, to)
|
from, to, _, err = r.findParentAndLayer(from, to)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return -1, ErrLayerUnknown
|
return -1, ErrLayerUnknown
|
||||||
}
|
}
|
File diff suppressed because it is too large
Load Diff
8
vendor/github.com/opencontainers/go-digest/algorithm.go
generated
vendored
8
vendor/github.com/opencontainers/go-digest/algorithm.go
generated
vendored
@ -125,6 +125,14 @@ func (a Algorithm) Hash() hash.Hash {
|
|||||||
return algorithms[a].New()
|
return algorithms[a].New()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Encode encodes the raw bytes of a digest, typically from a hash.Hash, into
|
||||||
|
// the encoded portion of the digest.
|
||||||
|
func (a Algorithm) Encode(d []byte) string {
|
||||||
|
// TODO(stevvooe): Currently, all algorithms use a hex encoding. When we
|
||||||
|
// add support for back registration, we can modify this accordingly.
|
||||||
|
return fmt.Sprintf("%x", d)
|
||||||
|
}
|
||||||
|
|
||||||
// FromReader returns the digest of the reader using the algorithm.
|
// FromReader returns the digest of the reader using the algorithm.
|
||||||
func (a Algorithm) FromReader(rd io.Reader) (Digest, error) {
|
func (a Algorithm) FromReader(rd io.Reader) (Digest, error) {
|
||||||
digester := a.Digester()
|
digester := a.Digester()
|
||||||
|
22
vendor/github.com/opencontainers/go-digest/digest.go
generated
vendored
22
vendor/github.com/opencontainers/go-digest/digest.go
generated
vendored
@ -45,16 +45,21 @@ func NewDigest(alg Algorithm, h hash.Hash) Digest {
|
|||||||
// functions. This is also useful for rebuilding digests from binary
|
// functions. This is also useful for rebuilding digests from binary
|
||||||
// serializations.
|
// serializations.
|
||||||
func NewDigestFromBytes(alg Algorithm, p []byte) Digest {
|
func NewDigestFromBytes(alg Algorithm, p []byte) Digest {
|
||||||
return Digest(fmt.Sprintf("%s:%x", alg, p))
|
return NewDigestFromEncoded(alg, alg.Encode(p))
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewDigestFromHex returns a Digest from alg and a the hex encoded digest.
|
// NewDigestFromHex is deprecated. Please use NewDigestFromEncoded.
|
||||||
func NewDigestFromHex(alg, hex string) Digest {
|
func NewDigestFromHex(alg, hex string) Digest {
|
||||||
return Digest(fmt.Sprintf("%s:%s", alg, hex))
|
return NewDigestFromEncoded(Algorithm(alg), hex)
|
||||||
|
}
|
||||||
|
|
||||||
|
// NewDigestFromEncoded returns a Digest from alg and the encoded digest.
|
||||||
|
func NewDigestFromEncoded(alg Algorithm, encoded string) Digest {
|
||||||
|
return Digest(fmt.Sprintf("%s:%s", alg, encoded))
|
||||||
}
|
}
|
||||||
|
|
||||||
// DigestRegexp matches valid digest types.
|
// DigestRegexp matches valid digest types.
|
||||||
var DigestRegexp = regexp.MustCompile(`[a-zA-Z0-9-_+.]+:[a-fA-F0-9]+`)
|
var DigestRegexp = regexp.MustCompile(`[a-z0-9]+(?:[.+_-][a-z0-9]+)*:[a-zA-Z0-9=_-]+`)
|
||||||
|
|
||||||
// DigestRegexpAnchored matches valid digest types, anchored to the start and end of the match.
|
// DigestRegexpAnchored matches valid digest types, anchored to the start and end of the match.
|
||||||
var DigestRegexpAnchored = regexp.MustCompile(`^` + DigestRegexp.String() + `$`)
|
var DigestRegexpAnchored = regexp.MustCompile(`^` + DigestRegexp.String() + `$`)
|
||||||
@ -133,12 +138,17 @@ func (d Digest) Verifier() Verifier {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Hex returns the hex digest portion of the digest. This will panic if the
|
// Encoded returns the encoded portion of the digest. This will panic if the
|
||||||
// underlying digest is not in a valid format.
|
// underlying digest is not in a valid format.
|
||||||
func (d Digest) Hex() string {
|
func (d Digest) Encoded() string {
|
||||||
return string(d[d.sepIndex()+1:])
|
return string(d[d.sepIndex()+1:])
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Hex is deprecated. Please use Digest.Encoded.
|
||||||
|
func (d Digest) Hex() string {
|
||||||
|
return d.Encoded()
|
||||||
|
}
|
||||||
|
|
||||||
func (d Digest) String() string {
|
func (d Digest) String() string {
|
||||||
return string(d)
|
return string(d)
|
||||||
}
|
}
|
||||||
|
94
vendor/golang.org/x/net/http2/server.go
generated
vendored
94
vendor/golang.org/x/net/http2/server.go
generated
vendored
@ -292,7 +292,7 @@ func (s *Server) ServeConn(c net.Conn, opts *ServeConnOpts) {
|
|||||||
streams: make(map[uint32]*stream),
|
streams: make(map[uint32]*stream),
|
||||||
readFrameCh: make(chan readFrameResult),
|
readFrameCh: make(chan readFrameResult),
|
||||||
wantWriteFrameCh: make(chan FrameWriteRequest, 8),
|
wantWriteFrameCh: make(chan FrameWriteRequest, 8),
|
||||||
wantStartPushCh: make(chan startPushRequest, 8),
|
serveMsgCh: make(chan interface{}, 8),
|
||||||
wroteFrameCh: make(chan frameWriteResult, 1), // buffered; one send in writeFrameAsync
|
wroteFrameCh: make(chan frameWriteResult, 1), // buffered; one send in writeFrameAsync
|
||||||
bodyReadCh: make(chan bodyReadMsg), // buffering doesn't matter either way
|
bodyReadCh: make(chan bodyReadMsg), // buffering doesn't matter either way
|
||||||
doneServing: make(chan struct{}),
|
doneServing: make(chan struct{}),
|
||||||
@ -405,10 +405,9 @@ type serverConn struct {
|
|||||||
doneServing chan struct{} // closed when serverConn.serve ends
|
doneServing chan struct{} // closed when serverConn.serve ends
|
||||||
readFrameCh chan readFrameResult // written by serverConn.readFrames
|
readFrameCh chan readFrameResult // written by serverConn.readFrames
|
||||||
wantWriteFrameCh chan FrameWriteRequest // from handlers -> serve
|
wantWriteFrameCh chan FrameWriteRequest // from handlers -> serve
|
||||||
wantStartPushCh chan startPushRequest // from handlers -> serve
|
|
||||||
wroteFrameCh chan frameWriteResult // from writeFrameAsync -> serve, tickles more frame writes
|
wroteFrameCh chan frameWriteResult // from writeFrameAsync -> serve, tickles more frame writes
|
||||||
bodyReadCh chan bodyReadMsg // from handlers -> serve
|
bodyReadCh chan bodyReadMsg // from handlers -> serve
|
||||||
testHookCh chan func(int) // code to run on the serve loop
|
serveMsgCh chan interface{} // misc messages & code to send to / run on the serve loop
|
||||||
flow flow // conn-wide (not stream-specific) outbound flow control
|
flow flow // conn-wide (not stream-specific) outbound flow control
|
||||||
inflow flow // conn-wide inbound flow control
|
inflow flow // conn-wide inbound flow control
|
||||||
tlsState *tls.ConnectionState // shared by all handlers, like net/http
|
tlsState *tls.ConnectionState // shared by all handlers, like net/http
|
||||||
@ -440,10 +439,8 @@ type serverConn struct {
|
|||||||
inFrameScheduleLoop bool // whether we're in the scheduleFrameWrite loop
|
inFrameScheduleLoop bool // whether we're in the scheduleFrameWrite loop
|
||||||
needToSendGoAway bool // we need to schedule a GOAWAY frame write
|
needToSendGoAway bool // we need to schedule a GOAWAY frame write
|
||||||
goAwayCode ErrCode
|
goAwayCode ErrCode
|
||||||
shutdownTimerCh <-chan time.Time // nil until used
|
|
||||||
shutdownTimer *time.Timer // nil until used
|
shutdownTimer *time.Timer // nil until used
|
||||||
idleTimer *time.Timer // nil if unused
|
idleTimer *time.Timer // nil if unused
|
||||||
idleTimerCh <-chan time.Time // nil if unused
|
|
||||||
|
|
||||||
// Owned by the writeFrameAsync goroutine:
|
// Owned by the writeFrameAsync goroutine:
|
||||||
headerWriteBuf bytes.Buffer
|
headerWriteBuf bytes.Buffer
|
||||||
@ -748,19 +745,24 @@ func (sc *serverConn) serve() {
|
|||||||
sc.setConnState(http.StateIdle)
|
sc.setConnState(http.StateIdle)
|
||||||
|
|
||||||
if sc.srv.IdleTimeout != 0 {
|
if sc.srv.IdleTimeout != 0 {
|
||||||
sc.idleTimer = time.NewTimer(sc.srv.IdleTimeout)
|
sc.idleTimer = time.AfterFunc(sc.srv.IdleTimeout, sc.onIdleTimer)
|
||||||
defer sc.idleTimer.Stop()
|
defer sc.idleTimer.Stop()
|
||||||
sc.idleTimerCh = sc.idleTimer.C
|
|
||||||
}
|
}
|
||||||
|
|
||||||
var gracefulShutdownCh <-chan struct{}
|
var gracefulShutdownCh chan struct{}
|
||||||
if sc.hs != nil {
|
if sc.hs != nil {
|
||||||
gracefulShutdownCh = h1ServerShutdownChan(sc.hs)
|
ch := h1ServerShutdownChan(sc.hs)
|
||||||
|
if ch != nil {
|
||||||
|
gracefulShutdownCh = make(chan struct{})
|
||||||
|
go sc.awaitGracefulShutdown(ch, gracefulShutdownCh)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
go sc.readFrames() // closed by defer sc.conn.Close above
|
go sc.readFrames() // closed by defer sc.conn.Close above
|
||||||
|
|
||||||
settingsTimer := time.NewTimer(firstSettingsTimeout)
|
settingsTimer := time.AfterFunc(firstSettingsTimeout, sc.onSettingsTimer)
|
||||||
|
defer settingsTimer.Stop()
|
||||||
|
|
||||||
loopNum := 0
|
loopNum := 0
|
||||||
for {
|
for {
|
||||||
loopNum++
|
loopNum++
|
||||||
@ -771,8 +773,6 @@ func (sc *serverConn) serve() {
|
|||||||
break
|
break
|
||||||
}
|
}
|
||||||
sc.writeFrame(wr)
|
sc.writeFrame(wr)
|
||||||
case spr := <-sc.wantStartPushCh:
|
|
||||||
sc.startPush(spr)
|
|
||||||
case res := <-sc.wroteFrameCh:
|
case res := <-sc.wroteFrameCh:
|
||||||
sc.wroteFrame(res)
|
sc.wroteFrame(res)
|
||||||
case res := <-sc.readFrameCh:
|
case res := <-sc.readFrameCh:
|
||||||
@ -780,26 +780,38 @@ func (sc *serverConn) serve() {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
res.readMore()
|
res.readMore()
|
||||||
if settingsTimer.C != nil {
|
if settingsTimer != nil {
|
||||||
settingsTimer.Stop()
|
settingsTimer.Stop()
|
||||||
settingsTimer.C = nil
|
settingsTimer = nil
|
||||||
}
|
}
|
||||||
case m := <-sc.bodyReadCh:
|
case m := <-sc.bodyReadCh:
|
||||||
sc.noteBodyRead(m.st, m.n)
|
sc.noteBodyRead(m.st, m.n)
|
||||||
case <-settingsTimer.C:
|
|
||||||
sc.logf("timeout waiting for SETTINGS frames from %v", sc.conn.RemoteAddr())
|
|
||||||
return
|
|
||||||
case <-gracefulShutdownCh:
|
case <-gracefulShutdownCh:
|
||||||
gracefulShutdownCh = nil
|
gracefulShutdownCh = nil
|
||||||
sc.startGracefulShutdown()
|
sc.startGracefulShutdown()
|
||||||
case <-sc.shutdownTimerCh:
|
case msg := <-sc.serveMsgCh:
|
||||||
sc.vlogf("GOAWAY close timer fired; closing conn from %v", sc.conn.RemoteAddr())
|
switch v := msg.(type) {
|
||||||
|
case func(int):
|
||||||
|
v(loopNum) // for testing
|
||||||
|
case *timerMessage:
|
||||||
|
switch v {
|
||||||
|
case settingsTimerMsg:
|
||||||
|
sc.logf("timeout waiting for SETTINGS frames from %v", sc.conn.RemoteAddr())
|
||||||
return
|
return
|
||||||
case <-sc.idleTimerCh:
|
case idleTimerMsg:
|
||||||
sc.vlogf("connection is idle")
|
sc.vlogf("connection is idle")
|
||||||
sc.goAway(ErrCodeNo)
|
sc.goAway(ErrCodeNo)
|
||||||
case fn := <-sc.testHookCh:
|
case shutdownTimerMsg:
|
||||||
fn(loopNum)
|
sc.vlogf("GOAWAY close timer fired; closing conn from %v", sc.conn.RemoteAddr())
|
||||||
|
return
|
||||||
|
default:
|
||||||
|
panic("unknown timer")
|
||||||
|
}
|
||||||
|
case *startPushRequest:
|
||||||
|
sc.startPush(v)
|
||||||
|
default:
|
||||||
|
panic(fmt.Sprintf("unexpected type %T", v))
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if sc.inGoAway && sc.curOpenStreams() == 0 && !sc.needToSendGoAway && !sc.writingFrame {
|
if sc.inGoAway && sc.curOpenStreams() == 0 && !sc.needToSendGoAway && !sc.writingFrame {
|
||||||
@ -808,6 +820,35 @@ func (sc *serverConn) serve() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (sc *serverConn) awaitGracefulShutdown(sharedCh <-chan struct{}, privateCh chan struct{}) {
|
||||||
|
select {
|
||||||
|
case <-sc.doneServing:
|
||||||
|
case <-sharedCh:
|
||||||
|
close(privateCh)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
type timerMessage int
|
||||||
|
|
||||||
|
// Timeout message values sent to serveMsgCh.
|
||||||
|
var (
|
||||||
|
settingsTimerMsg = new(timerMessage)
|
||||||
|
idleTimerMsg = new(timerMessage)
|
||||||
|
shutdownTimerMsg = new(timerMessage)
|
||||||
|
)
|
||||||
|
|
||||||
|
func (sc *serverConn) onSettingsTimer() { sc.sendServeMsg(settingsTimerMsg) }
|
||||||
|
func (sc *serverConn) onIdleTimer() { sc.sendServeMsg(idleTimerMsg) }
|
||||||
|
func (sc *serverConn) onShutdownTimer() { sc.sendServeMsg(shutdownTimerMsg) }
|
||||||
|
|
||||||
|
func (sc *serverConn) sendServeMsg(msg interface{}) {
|
||||||
|
sc.serveG.checkNotOn() // NOT
|
||||||
|
select {
|
||||||
|
case sc.serveMsgCh <- msg:
|
||||||
|
case <-sc.doneServing:
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// readPreface reads the ClientPreface greeting from the peer
|
// readPreface reads the ClientPreface greeting from the peer
|
||||||
// or returns an error on timeout or an invalid greeting.
|
// or returns an error on timeout or an invalid greeting.
|
||||||
func (sc *serverConn) readPreface() error {
|
func (sc *serverConn) readPreface() error {
|
||||||
@ -1160,8 +1201,7 @@ func (sc *serverConn) goAwayIn(code ErrCode, forceCloseIn time.Duration) {
|
|||||||
|
|
||||||
func (sc *serverConn) shutDownIn(d time.Duration) {
|
func (sc *serverConn) shutDownIn(d time.Duration) {
|
||||||
sc.serveG.check()
|
sc.serveG.check()
|
||||||
sc.shutdownTimer = time.NewTimer(d)
|
sc.shutdownTimer = time.AfterFunc(d, sc.onShutdownTimer)
|
||||||
sc.shutdownTimerCh = sc.shutdownTimer.C
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func (sc *serverConn) resetStream(se StreamError) {
|
func (sc *serverConn) resetStream(se StreamError) {
|
||||||
@ -2539,7 +2579,7 @@ func (w *responseWriter) push(target string, opts pushOptions) error {
|
|||||||
return fmt.Errorf("method %q must be GET or HEAD", opts.Method)
|
return fmt.Errorf("method %q must be GET or HEAD", opts.Method)
|
||||||
}
|
}
|
||||||
|
|
||||||
msg := startPushRequest{
|
msg := &startPushRequest{
|
||||||
parent: st,
|
parent: st,
|
||||||
method: opts.Method,
|
method: opts.Method,
|
||||||
url: u,
|
url: u,
|
||||||
@ -2552,7 +2592,7 @@ func (w *responseWriter) push(target string, opts pushOptions) error {
|
|||||||
return errClientDisconnected
|
return errClientDisconnected
|
||||||
case <-st.cw:
|
case <-st.cw:
|
||||||
return errStreamClosed
|
return errStreamClosed
|
||||||
case sc.wantStartPushCh <- msg:
|
case sc.serveMsgCh <- msg:
|
||||||
}
|
}
|
||||||
|
|
||||||
select {
|
select {
|
||||||
@ -2574,7 +2614,7 @@ type startPushRequest struct {
|
|||||||
done chan error
|
done chan error
|
||||||
}
|
}
|
||||||
|
|
||||||
func (sc *serverConn) startPush(msg startPushRequest) {
|
func (sc *serverConn) startPush(msg *startPushRequest) {
|
||||||
sc.serveG.check()
|
sc.serveG.check()
|
||||||
|
|
||||||
// http://tools.ietf.org/html/rfc7540#section-6.6.
|
// http://tools.ietf.org/html/rfc7540#section-6.6.
|
||||||
|
4
vendor/golang.org/x/sys/unix/asm_solaris_amd64.s
generated
vendored
4
vendor/golang.org/x/sys/unix/asm_solaris_amd64.s
generated
vendored
@ -10,8 +10,8 @@
|
|||||||
// System calls for amd64, Solaris are implemented in runtime/syscall_solaris.go
|
// System calls for amd64, Solaris are implemented in runtime/syscall_solaris.go
|
||||||
//
|
//
|
||||||
|
|
||||||
TEXT ·sysvicall6(SB),NOSPLIT,$0-64
|
TEXT ·sysvicall6(SB),NOSPLIT,$0-88
|
||||||
JMP syscall·sysvicall6(SB)
|
JMP syscall·sysvicall6(SB)
|
||||||
|
|
||||||
TEXT ·rawSysvicall6(SB),NOSPLIT,$0-64
|
TEXT ·rawSysvicall6(SB),NOSPLIT,$0-88
|
||||||
JMP syscall·rawSysvicall6(SB)
|
JMP syscall·rawSysvicall6(SB)
|
||||||
|
7
vendor/golang.org/x/sys/unix/sockcmsg_unix.go
generated
vendored
7
vendor/golang.org/x/sys/unix/sockcmsg_unix.go
generated
vendored
@ -13,9 +13,10 @@ import "unsafe"
|
|||||||
// Round the length of a raw sockaddr up to align it properly.
|
// Round the length of a raw sockaddr up to align it properly.
|
||||||
func cmsgAlignOf(salen int) int {
|
func cmsgAlignOf(salen int) int {
|
||||||
salign := sizeofPtr
|
salign := sizeofPtr
|
||||||
// NOTE: It seems like 64-bit Darwin and DragonFly BSD kernels
|
// NOTE: It seems like 64-bit Darwin, DragonFly BSD and
|
||||||
// still require 32-bit aligned access to network subsystem.
|
// Solaris kernels still require 32-bit aligned access to
|
||||||
if darwin64Bit || dragonfly64Bit {
|
// network subsystem.
|
||||||
|
if darwin64Bit || dragonfly64Bit || solaris64Bit {
|
||||||
salign = 4
|
salign = 4
|
||||||
}
|
}
|
||||||
return (salen + salign - 1) & ^(salign - 1)
|
return (salen + salign - 1) & ^(salign - 1)
|
||||||
|
1
vendor/golang.org/x/sys/unix/syscall_linux.go
generated
vendored
1
vendor/golang.org/x/sys/unix/syscall_linux.go
generated
vendored
@ -1038,6 +1038,7 @@ func Mount(source string, target string, fstype string, flags uintptr, data stri
|
|||||||
//sys Chroot(path string) (err error)
|
//sys Chroot(path string) (err error)
|
||||||
//sys ClockGettime(clockid int32, time *Timespec) (err error)
|
//sys ClockGettime(clockid int32, time *Timespec) (err error)
|
||||||
//sys Close(fd int) (err error)
|
//sys Close(fd int) (err error)
|
||||||
|
//sys CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error)
|
||||||
//sys Dup(oldfd int) (fd int, err error)
|
//sys Dup(oldfd int) (fd int, err error)
|
||||||
//sys Dup3(oldfd int, newfd int, flags int) (err error)
|
//sys Dup3(oldfd int, newfd int, flags int) (err error)
|
||||||
//sysnb EpollCreate(size int) (fd int, err error)
|
//sysnb EpollCreate(size int) (fd int, err error)
|
||||||
|
5
vendor/golang.org/x/sys/unix/syscall_linux_mips64x.go
generated
vendored
5
vendor/golang.org/x/sys/unix/syscall_linux_mips64x.go
generated
vendored
@ -7,6 +7,7 @@
|
|||||||
|
|
||||||
package unix
|
package unix
|
||||||
|
|
||||||
|
//sys Dup2(oldfd int, newfd int) (err error)
|
||||||
//sys EpollWait(epfd int, events []EpollEvent, msec int) (n int, err error)
|
//sys EpollWait(epfd int, events []EpollEvent, msec int) (n int, err error)
|
||||||
//sys Fchown(fd int, uid int, gid int) (err error)
|
//sys Fchown(fd int, uid int, gid int) (err error)
|
||||||
//sys Fstatfs(fd int, buf *Statfs_t) (err error)
|
//sys Fstatfs(fd int, buf *Statfs_t) (err error)
|
||||||
@ -182,9 +183,9 @@ func fillStat_t(s *Stat_t, st *stat_t) {
|
|||||||
s.Blocks = st.Blocks
|
s.Blocks = st.Blocks
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *PtraceRegs) PC() uint64 { return r.Regs[64] }
|
func (r *PtraceRegs) PC() uint64 { return r.Epc }
|
||||||
|
|
||||||
func (r *PtraceRegs) SetPC(pc uint64) { r.Regs[64] = pc }
|
func (r *PtraceRegs) SetPC(pc uint64) { r.Epc = pc }
|
||||||
|
|
||||||
func (iov *Iovec) SetLen(length int) {
|
func (iov *Iovec) SetLen(length int) {
|
||||||
iov.Len = uint64(length)
|
iov.Len = uint64(length)
|
||||||
|
4
vendor/golang.org/x/sys/unix/syscall_linux_mipsx.go
generated
vendored
4
vendor/golang.org/x/sys/unix/syscall_linux_mipsx.go
generated
vendored
@ -211,9 +211,9 @@ func Setrlimit(resource int, rlim *Rlimit) (err error) {
|
|||||||
return setrlimit(resource, &rl)
|
return setrlimit(resource, &rl)
|
||||||
}
|
}
|
||||||
|
|
||||||
func (r *PtraceRegs) PC() uint64 { return uint64(r.Regs[64]) }
|
func (r *PtraceRegs) PC() uint64 { return r.Epc }
|
||||||
|
|
||||||
func (r *PtraceRegs) SetPC(pc uint64) { r.Regs[64] = uint32(pc) }
|
func (r *PtraceRegs) SetPC(pc uint64) { r.Epc = pc }
|
||||||
|
|
||||||
func (iov *Iovec) SetLen(length int) {
|
func (iov *Iovec) SetLen(length int) {
|
||||||
iov.Len = uint32(length)
|
iov.Len = uint32(length)
|
||||||
|
24
vendor/golang.org/x/sys/unix/syscall_solaris.go
generated
vendored
24
vendor/golang.org/x/sys/unix/syscall_solaris.go
generated
vendored
@ -422,7 +422,7 @@ func Accept(fd int) (nfd int, sa Sockaddr, err error) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
//sys recvmsg(s int, msg *Msghdr, flags int) (n int, err error) = libsocket.recvmsg
|
//sys recvmsg(s int, msg *Msghdr, flags int) (n int, err error) = libsocket.__xnet_recvmsg
|
||||||
|
|
||||||
func Recvmsg(fd int, p, oob []byte, flags int) (n, oobn int, recvflags int, from Sockaddr, err error) {
|
func Recvmsg(fd int, p, oob []byte, flags int) (n, oobn int, recvflags int, from Sockaddr, err error) {
|
||||||
var msg Msghdr
|
var msg Msghdr
|
||||||
@ -441,7 +441,7 @@ func Recvmsg(fd int, p, oob []byte, flags int) (n, oobn int, recvflags int, from
|
|||||||
iov.Base = &dummy
|
iov.Base = &dummy
|
||||||
iov.SetLen(1)
|
iov.SetLen(1)
|
||||||
}
|
}
|
||||||
msg.Accrights = (*int8)(unsafe.Pointer(&oob[0]))
|
msg.Accrightslen = int32(len(oob))
|
||||||
}
|
}
|
||||||
msg.Iov = &iov
|
msg.Iov = &iov
|
||||||
msg.Iovlen = 1
|
msg.Iovlen = 1
|
||||||
@ -461,7 +461,7 @@ func Sendmsg(fd int, p, oob []byte, to Sockaddr, flags int) (err error) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
//sys sendmsg(s int, msg *Msghdr, flags int) (n int, err error) = libsocket.sendmsg
|
//sys sendmsg(s int, msg *Msghdr, flags int) (n int, err error) = libsocket.__xnet_sendmsg
|
||||||
|
|
||||||
func SendmsgN(fd int, p, oob []byte, to Sockaddr, flags int) (n int, err error) {
|
func SendmsgN(fd int, p, oob []byte, to Sockaddr, flags int) (n int, err error) {
|
||||||
var ptr unsafe.Pointer
|
var ptr unsafe.Pointer
|
||||||
@ -487,7 +487,7 @@ func SendmsgN(fd int, p, oob []byte, to Sockaddr, flags int) (n int, err error)
|
|||||||
iov.Base = &dummy
|
iov.Base = &dummy
|
||||||
iov.SetLen(1)
|
iov.SetLen(1)
|
||||||
}
|
}
|
||||||
msg.Accrights = (*int8)(unsafe.Pointer(&oob[0]))
|
msg.Accrightslen = int32(len(oob))
|
||||||
}
|
}
|
||||||
msg.Iov = &iov
|
msg.Iov = &iov
|
||||||
msg.Iovlen = 1
|
msg.Iovlen = 1
|
||||||
@ -583,6 +583,7 @@ func IoctlGetTermio(fd int, req int) (*Termio, error) {
|
|||||||
//sys Fdatasync(fd int) (err error)
|
//sys Fdatasync(fd int) (err error)
|
||||||
//sys Fpathconf(fd int, name int) (val int, err error)
|
//sys Fpathconf(fd int, name int) (val int, err error)
|
||||||
//sys Fstat(fd int, stat *Stat_t) (err error)
|
//sys Fstat(fd int, stat *Stat_t) (err error)
|
||||||
|
//sys Fstatvfs(fd int, vfsstat *Statvfs_t) (err error)
|
||||||
//sys Getdents(fd int, buf []byte, basep *uintptr) (n int, err error)
|
//sys Getdents(fd int, buf []byte, basep *uintptr) (n int, err error)
|
||||||
//sysnb Getgid() (gid int)
|
//sysnb Getgid() (gid int)
|
||||||
//sysnb Getpid() (pid int)
|
//sysnb Getpid() (pid int)
|
||||||
@ -599,7 +600,7 @@ func IoctlGetTermio(fd int, req int) (*Termio, error) {
|
|||||||
//sys Kill(pid int, signum syscall.Signal) (err error)
|
//sys Kill(pid int, signum syscall.Signal) (err error)
|
||||||
//sys Lchown(path string, uid int, gid int) (err error)
|
//sys Lchown(path string, uid int, gid int) (err error)
|
||||||
//sys Link(path string, link string) (err error)
|
//sys Link(path string, link string) (err error)
|
||||||
//sys Listen(s int, backlog int) (err error) = libsocket.listen
|
//sys Listen(s int, backlog int) (err error) = libsocket.__xnet_llisten
|
||||||
//sys Lstat(path string, stat *Stat_t) (err error)
|
//sys Lstat(path string, stat *Stat_t) (err error)
|
||||||
//sys Madvise(b []byte, advice int) (err error)
|
//sys Madvise(b []byte, advice int) (err error)
|
||||||
//sys Mkdir(path string, mode uint32) (err error)
|
//sys Mkdir(path string, mode uint32) (err error)
|
||||||
@ -639,6 +640,7 @@ func IoctlGetTermio(fd int, req int) (*Termio, error) {
|
|||||||
//sysnb Setuid(uid int) (err error)
|
//sysnb Setuid(uid int) (err error)
|
||||||
//sys Shutdown(s int, how int) (err error) = libsocket.shutdown
|
//sys Shutdown(s int, how int) (err error) = libsocket.shutdown
|
||||||
//sys Stat(path string, stat *Stat_t) (err error)
|
//sys Stat(path string, stat *Stat_t) (err error)
|
||||||
|
//sys Statvfs(path string, vfsstat *Statvfs_t) (err error)
|
||||||
//sys Symlink(path string, link string) (err error)
|
//sys Symlink(path string, link string) (err error)
|
||||||
//sys Sync() (err error)
|
//sys Sync() (err error)
|
||||||
//sysnb Times(tms *Tms) (ticks uintptr, err error)
|
//sysnb Times(tms *Tms) (ticks uintptr, err error)
|
||||||
@ -652,15 +654,15 @@ func IoctlGetTermio(fd int, req int) (*Termio, error) {
|
|||||||
//sys Unlinkat(dirfd int, path string, flags int) (err error)
|
//sys Unlinkat(dirfd int, path string, flags int) (err error)
|
||||||
//sys Ustat(dev int, ubuf *Ustat_t) (err error)
|
//sys Ustat(dev int, ubuf *Ustat_t) (err error)
|
||||||
//sys Utime(path string, buf *Utimbuf) (err error)
|
//sys Utime(path string, buf *Utimbuf) (err error)
|
||||||
//sys bind(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) = libsocket.bind
|
//sys bind(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) = libsocket.__xnet_bind
|
||||||
//sys connect(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) = libsocket.connect
|
//sys connect(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) = libsocket.__xnet_connect
|
||||||
//sys mmap(addr uintptr, length uintptr, prot int, flag int, fd int, pos int64) (ret uintptr, err error)
|
//sys mmap(addr uintptr, length uintptr, prot int, flag int, fd int, pos int64) (ret uintptr, err error)
|
||||||
//sys munmap(addr uintptr, length uintptr) (err error)
|
//sys munmap(addr uintptr, length uintptr) (err error)
|
||||||
//sys sendto(s int, buf []byte, flags int, to unsafe.Pointer, addrlen _Socklen) (err error) = libsocket.sendto
|
//sys sendto(s int, buf []byte, flags int, to unsafe.Pointer, addrlen _Socklen) (err error) = libsocket.__xnet_sendto
|
||||||
//sys socket(domain int, typ int, proto int) (fd int, err error) = libsocket.socket
|
//sys socket(domain int, typ int, proto int) (fd int, err error) = libsocket.__xnet_socket
|
||||||
//sysnb socketpair(domain int, typ int, proto int, fd *[2]int32) (err error) = libsocket.socketpair
|
//sysnb socketpair(domain int, typ int, proto int, fd *[2]int32) (err error) = libsocket.__xnet_socketpair
|
||||||
//sys write(fd int, p []byte) (n int, err error)
|
//sys write(fd int, p []byte) (n int, err error)
|
||||||
//sys getsockopt(s int, level int, name int, val unsafe.Pointer, vallen *_Socklen) (err error) = libsocket.getsockopt
|
//sys getsockopt(s int, level int, name int, val unsafe.Pointer, vallen *_Socklen) (err error) = libsocket.__xnet_getsockopt
|
||||||
//sysnb getpeername(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (err error) = libsocket.getpeername
|
//sysnb getpeername(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (err error) = libsocket.getpeername
|
||||||
//sys setsockopt(s int, level int, name int, val unsafe.Pointer, vallen uintptr) (err error) = libsocket.setsockopt
|
//sys setsockopt(s int, level int, name int, val unsafe.Pointer, vallen uintptr) (err error) = libsocket.setsockopt
|
||||||
//sys recvfrom(fd int, p []byte, flags int, from *RawSockaddrAny, fromlen *_Socklen) (n int, err error) = libsocket.recvfrom
|
//sys recvfrom(fd int, p []byte, flags int, from *RawSockaddrAny, fromlen *_Socklen) (n int, err error) = libsocket.recvfrom
|
||||||
|
1
vendor/golang.org/x/sys/unix/syscall_unix.go
generated
vendored
1
vendor/golang.org/x/sys/unix/syscall_unix.go
generated
vendored
@ -23,6 +23,7 @@ const (
|
|||||||
darwin64Bit = runtime.GOOS == "darwin" && sizeofPtr == 8
|
darwin64Bit = runtime.GOOS == "darwin" && sizeofPtr == 8
|
||||||
dragonfly64Bit = runtime.GOOS == "dragonfly" && sizeofPtr == 8
|
dragonfly64Bit = runtime.GOOS == "dragonfly" && sizeofPtr == 8
|
||||||
netbsd32Bit = runtime.GOOS == "netbsd" && sizeofPtr == 4
|
netbsd32Bit = runtime.GOOS == "netbsd" && sizeofPtr == 4
|
||||||
|
solaris64Bit = runtime.GOOS == "solaris" && sizeofPtr == 8
|
||||||
)
|
)
|
||||||
|
|
||||||
// Do the interface allocations only once for common
|
// Do the interface allocations only once for common
|
||||||
|
7
vendor/golang.org/x/sys/unix/types_solaris.go
generated
vendored
7
vendor/golang.org/x/sys/unix/types_solaris.go
generated
vendored
@ -37,6 +37,7 @@ package unix
|
|||||||
#include <sys/signal.h>
|
#include <sys/signal.h>
|
||||||
#include <sys/socket.h>
|
#include <sys/socket.h>
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
|
#include <sys/statvfs.h>
|
||||||
#include <sys/time.h>
|
#include <sys/time.h>
|
||||||
#include <sys/times.h>
|
#include <sys/times.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
@ -139,6 +140,12 @@ type Flock_t C.struct_flock
|
|||||||
|
|
||||||
type Dirent C.struct_dirent
|
type Dirent C.struct_dirent
|
||||||
|
|
||||||
|
// Filesystems
|
||||||
|
|
||||||
|
type _Fsblkcnt_t C.fsblkcnt_t
|
||||||
|
|
||||||
|
type Statvfs_t C.struct_statvfs
|
||||||
|
|
||||||
// Sockets
|
// Sockets
|
||||||
|
|
||||||
type RawSockaddrInet4 C.struct_sockaddr_in
|
type RawSockaddrInet4 C.struct_sockaddr_in
|
||||||
|
49
vendor/golang.org/x/sys/unix/zerrors_solaris_amd64.go
generated
vendored
49
vendor/golang.org/x/sys/unix/zerrors_solaris_amd64.go
generated
vendored
@ -1,5 +1,5 @@
|
|||||||
// mkerrors.sh -m64
|
// mkerrors.sh -m64
|
||||||
// MACHINE GENERATED BY THE COMMAND ABOVE; DO NOT EDIT
|
// Code generated by the command above; see README.md. DO NOT EDIT.
|
||||||
|
|
||||||
// +build amd64,solaris
|
// +build amd64,solaris
|
||||||
|
|
||||||
@ -159,7 +159,12 @@ const (
|
|||||||
BPF_W = 0x0
|
BPF_W = 0x0
|
||||||
BPF_X = 0x8
|
BPF_X = 0x8
|
||||||
BRKINT = 0x2
|
BRKINT = 0x2
|
||||||
|
BS0 = 0x0
|
||||||
|
BS1 = 0x2000
|
||||||
|
BSDLY = 0x2000
|
||||||
|
CBAUD = 0xf
|
||||||
CFLUSH = 0xf
|
CFLUSH = 0xf
|
||||||
|
CIBAUD = 0xf0000
|
||||||
CLOCAL = 0x800
|
CLOCAL = 0x800
|
||||||
CLOCK_HIGHRES = 0x4
|
CLOCK_HIGHRES = 0x4
|
||||||
CLOCK_LEVEL = 0xa
|
CLOCK_LEVEL = 0xa
|
||||||
@ -169,7 +174,13 @@ const (
|
|||||||
CLOCK_REALTIME = 0x3
|
CLOCK_REALTIME = 0x3
|
||||||
CLOCK_THREAD_CPUTIME_ID = 0x2
|
CLOCK_THREAD_CPUTIME_ID = 0x2
|
||||||
CLOCK_VIRTUAL = 0x1
|
CLOCK_VIRTUAL = 0x1
|
||||||
|
CR0 = 0x0
|
||||||
|
CR1 = 0x200
|
||||||
|
CR2 = 0x400
|
||||||
|
CR3 = 0x600
|
||||||
|
CRDLY = 0x600
|
||||||
CREAD = 0x80
|
CREAD = 0x80
|
||||||
|
CRTSCTS = 0x80000000
|
||||||
CS5 = 0x0
|
CS5 = 0x0
|
||||||
CS6 = 0x10
|
CS6 = 0x10
|
||||||
CS7 = 0x20
|
CS7 = 0x20
|
||||||
@ -276,6 +287,9 @@ const (
|
|||||||
FD_CLOEXEC = 0x1
|
FD_CLOEXEC = 0x1
|
||||||
FD_NFDBITS = 0x40
|
FD_NFDBITS = 0x40
|
||||||
FD_SETSIZE = 0x10000
|
FD_SETSIZE = 0x10000
|
||||||
|
FF0 = 0x0
|
||||||
|
FF1 = 0x8000
|
||||||
|
FFDLY = 0x8000
|
||||||
FLUSHALL = 0x1
|
FLUSHALL = 0x1
|
||||||
FLUSHDATA = 0x0
|
FLUSHDATA = 0x0
|
||||||
FLUSHO = 0x2000
|
FLUSHO = 0x2000
|
||||||
@ -290,6 +304,10 @@ const (
|
|||||||
F_DUP2FD_CLOEXEC = 0x24
|
F_DUP2FD_CLOEXEC = 0x24
|
||||||
F_DUPFD = 0x0
|
F_DUPFD = 0x0
|
||||||
F_DUPFD_CLOEXEC = 0x25
|
F_DUPFD_CLOEXEC = 0x25
|
||||||
|
F_FLOCK = 0x35
|
||||||
|
F_FLOCK64 = 0x35
|
||||||
|
F_FLOCKW = 0x36
|
||||||
|
F_FLOCKW64 = 0x36
|
||||||
F_FREESP = 0xb
|
F_FREESP = 0xb
|
||||||
F_FREESP64 = 0xb
|
F_FREESP64 = 0xb
|
||||||
F_GETFD = 0x1
|
F_GETFD = 0x1
|
||||||
@ -304,6 +322,12 @@ const (
|
|||||||
F_MDACC = 0x20
|
F_MDACC = 0x20
|
||||||
F_NODNY = 0x0
|
F_NODNY = 0x0
|
||||||
F_NPRIV = 0x10
|
F_NPRIV = 0x10
|
||||||
|
F_OFD_GETLK = 0x2f
|
||||||
|
F_OFD_GETLK64 = 0x2f
|
||||||
|
F_OFD_SETLK = 0x30
|
||||||
|
F_OFD_SETLK64 = 0x30
|
||||||
|
F_OFD_SETLKW = 0x31
|
||||||
|
F_OFD_SETLKW64 = 0x31
|
||||||
F_PRIV = 0xf
|
F_PRIV = 0xf
|
||||||
F_QUOTACTL = 0x11
|
F_QUOTACTL = 0x11
|
||||||
F_RDACC = 0x1
|
F_RDACC = 0x1
|
||||||
@ -332,6 +356,7 @@ const (
|
|||||||
F_WRDNY = 0x2
|
F_WRDNY = 0x2
|
||||||
F_WRLCK = 0x2
|
F_WRLCK = 0x2
|
||||||
HUPCL = 0x400
|
HUPCL = 0x400
|
||||||
|
IBSHIFT = 0x10
|
||||||
ICANON = 0x2
|
ICANON = 0x2
|
||||||
ICRNL = 0x100
|
ICRNL = 0x100
|
||||||
IEXTEN = 0x8000
|
IEXTEN = 0x8000
|
||||||
@ -589,15 +614,21 @@ const (
|
|||||||
IP_UNSPEC_SRC = 0x42
|
IP_UNSPEC_SRC = 0x42
|
||||||
ISIG = 0x1
|
ISIG = 0x1
|
||||||
ISTRIP = 0x20
|
ISTRIP = 0x20
|
||||||
|
IUCLC = 0x200
|
||||||
IXANY = 0x800
|
IXANY = 0x800
|
||||||
IXOFF = 0x1000
|
IXOFF = 0x1000
|
||||||
IXON = 0x400
|
IXON = 0x400
|
||||||
|
LOCK_EX = 0x2
|
||||||
|
LOCK_NB = 0x4
|
||||||
|
LOCK_SH = 0x1
|
||||||
|
LOCK_UN = 0x8
|
||||||
MADV_ACCESS_DEFAULT = 0x6
|
MADV_ACCESS_DEFAULT = 0x6
|
||||||
MADV_ACCESS_LWP = 0x7
|
MADV_ACCESS_LWP = 0x7
|
||||||
MADV_ACCESS_MANY = 0x8
|
MADV_ACCESS_MANY = 0x8
|
||||||
MADV_DONTNEED = 0x4
|
MADV_DONTNEED = 0x4
|
||||||
MADV_FREE = 0x5
|
MADV_FREE = 0x5
|
||||||
MADV_NORMAL = 0x0
|
MADV_NORMAL = 0x0
|
||||||
|
MADV_PURGE = 0x9
|
||||||
MADV_RANDOM = 0x1
|
MADV_RANDOM = 0x1
|
||||||
MADV_SEQUENTIAL = 0x2
|
MADV_SEQUENTIAL = 0x2
|
||||||
MADV_WILLNEED = 0x3
|
MADV_WILLNEED = 0x3
|
||||||
@ -605,6 +636,7 @@ const (
|
|||||||
MAP_ALIGN = 0x200
|
MAP_ALIGN = 0x200
|
||||||
MAP_ANON = 0x100
|
MAP_ANON = 0x100
|
||||||
MAP_ANONYMOUS = 0x100
|
MAP_ANONYMOUS = 0x100
|
||||||
|
MAP_FILE = 0x0
|
||||||
MAP_FIXED = 0x10
|
MAP_FIXED = 0x10
|
||||||
MAP_INITDATA = 0x800
|
MAP_INITDATA = 0x800
|
||||||
MAP_NORESERVE = 0x40
|
MAP_NORESERVE = 0x40
|
||||||
@ -632,10 +664,14 @@ const (
|
|||||||
MS_OLDSYNC = 0x0
|
MS_OLDSYNC = 0x0
|
||||||
MS_SYNC = 0x4
|
MS_SYNC = 0x4
|
||||||
M_FLUSH = 0x86
|
M_FLUSH = 0x86
|
||||||
|
NL0 = 0x0
|
||||||
|
NL1 = 0x100
|
||||||
|
NLDLY = 0x100
|
||||||
NOFLSH = 0x80
|
NOFLSH = 0x80
|
||||||
OCRNL = 0x8
|
OCRNL = 0x8
|
||||||
OFDEL = 0x80
|
OFDEL = 0x80
|
||||||
OFILL = 0x40
|
OFILL = 0x40
|
||||||
|
OLCUC = 0x2
|
||||||
ONLCR = 0x4
|
ONLCR = 0x4
|
||||||
ONLRET = 0x20
|
ONLRET = 0x20
|
||||||
ONOCR = 0x10
|
ONOCR = 0x10
|
||||||
@ -955,12 +991,21 @@ const (
|
|||||||
SO_USELOOPBACK = 0x40
|
SO_USELOOPBACK = 0x40
|
||||||
SO_VRRP = 0x1017
|
SO_VRRP = 0x1017
|
||||||
SO_WROFF = 0x2
|
SO_WROFF = 0x2
|
||||||
|
TAB0 = 0x0
|
||||||
|
TAB1 = 0x800
|
||||||
|
TAB2 = 0x1000
|
||||||
|
TAB3 = 0x1800
|
||||||
|
TABDLY = 0x1800
|
||||||
TCFLSH = 0x5407
|
TCFLSH = 0x5407
|
||||||
TCGETA = 0x5401
|
TCGETA = 0x5401
|
||||||
TCGETS = 0x540d
|
TCGETS = 0x540d
|
||||||
TCIFLUSH = 0x0
|
TCIFLUSH = 0x0
|
||||||
|
TCIOFF = 0x2
|
||||||
TCIOFLUSH = 0x2
|
TCIOFLUSH = 0x2
|
||||||
|
TCION = 0x3
|
||||||
TCOFLUSH = 0x1
|
TCOFLUSH = 0x1
|
||||||
|
TCOOFF = 0x0
|
||||||
|
TCOON = 0x1
|
||||||
TCP_ABORT_THRESHOLD = 0x11
|
TCP_ABORT_THRESHOLD = 0x11
|
||||||
TCP_ANONPRIVBIND = 0x20
|
TCP_ANONPRIVBIND = 0x20
|
||||||
TCP_CONN_ABORT_THRESHOLD = 0x13
|
TCP_CONN_ABORT_THRESHOLD = 0x13
|
||||||
@ -1089,6 +1134,8 @@ const (
|
|||||||
WSTOPPED = 0x4
|
WSTOPPED = 0x4
|
||||||
WTRAPPED = 0x2
|
WTRAPPED = 0x2
|
||||||
WUNTRACED = 0x4
|
WUNTRACED = 0x4
|
||||||
|
XCASE = 0x4
|
||||||
|
XTABS = 0x1800
|
||||||
)
|
)
|
||||||
|
|
||||||
// Errors
|
// Errors
|
||||||
|
11
vendor/golang.org/x/sys/unix/zsyscall_linux_386.go
generated
vendored
11
vendor/golang.org/x/sys/unix/zsyscall_linux_386.go
generated
vendored
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
|
11
vendor/golang.org/x/sys/unix/zsyscall_linux_amd64.go
generated
vendored
11
vendor/golang.org/x/sys/unix/zsyscall_linux_amd64.go
generated
vendored
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
|
11
vendor/golang.org/x/sys/unix/zsyscall_linux_arm.go
generated
vendored
11
vendor/golang.org/x/sys/unix/zsyscall_linux_arm.go
generated
vendored
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
|
11
vendor/golang.org/x/sys/unix/zsyscall_linux_arm64.go
generated
vendored
11
vendor/golang.org/x/sys/unix/zsyscall_linux_arm64.go
generated
vendored
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
|
11
vendor/golang.org/x/sys/unix/zsyscall_linux_mips.go
generated
vendored
11
vendor/golang.org/x/sys/unix/zsyscall_linux_mips.go
generated
vendored
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
|
21
vendor/golang.org/x/sys/unix/zsyscall_linux_mips64.go
generated
vendored
21
vendor/golang.org/x/sys/unix/zsyscall_linux_mips64.go
generated
vendored
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
@ -1194,6 +1205,16 @@ func Munlockall() (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func Dup2(oldfd int, newfd int) (err error) {
|
||||||
|
_, _, e1 := Syscall(SYS_DUP2, uintptr(oldfd), uintptr(newfd), 0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func EpollWait(epfd int, events []EpollEvent, msec int) (n int, err error) {
|
func EpollWait(epfd int, events []EpollEvent, msec int) (n int, err error) {
|
||||||
var _p0 unsafe.Pointer
|
var _p0 unsafe.Pointer
|
||||||
if len(events) > 0 {
|
if len(events) > 0 {
|
||||||
|
21
vendor/golang.org/x/sys/unix/zsyscall_linux_mips64le.go
generated
vendored
21
vendor/golang.org/x/sys/unix/zsyscall_linux_mips64le.go
generated
vendored
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
@ -1194,6 +1205,16 @@ func Munlockall() (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func Dup2(oldfd int, newfd int) (err error) {
|
||||||
|
_, _, e1 := Syscall(SYS_DUP2, uintptr(oldfd), uintptr(newfd), 0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func EpollWait(epfd int, events []EpollEvent, msec int) (n int, err error) {
|
func EpollWait(epfd int, events []EpollEvent, msec int) (n int, err error) {
|
||||||
var _p0 unsafe.Pointer
|
var _p0 unsafe.Pointer
|
||||||
if len(events) > 0 {
|
if len(events) > 0 {
|
||||||
|
11
vendor/golang.org/x/sys/unix/zsyscall_linux_mipsle.go
generated
vendored
11
vendor/golang.org/x/sys/unix/zsyscall_linux_mipsle.go
generated
vendored
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
|
11
vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64.go
generated
vendored
11
vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64.go
generated
vendored
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
|
11
vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64le.go
generated
vendored
11
vendor/golang.org/x/sys/unix/zsyscall_linux_ppc64le.go
generated
vendored
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
|
11
vendor/golang.org/x/sys/unix/zsyscall_linux_s390x.go
generated
vendored
11
vendor/golang.org/x/sys/unix/zsyscall_linux_s390x.go
generated
vendored
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
|
13
vendor/golang.org/x/sys/unix/zsyscall_linux_sparc64.go
generated
vendored
13
vendor/golang.org/x/sys/unix/zsyscall_linux_sparc64.go
generated
vendored
@ -1,5 +1,5 @@
|
|||||||
// mksyscall.pl -tags linux,sparc64 syscall_linux.go syscall_linux_sparc64.go
|
// mksyscall.pl -tags linux,sparc64 syscall_linux.go syscall_linux_sparc64.go
|
||||||
// MACHINE GENERATED BY THE COMMAND ABOVE; DO NOT EDIT
|
// Code generated by the command above; see README.md. DO NOT EDIT.
|
||||||
|
|
||||||
// +build linux,sparc64
|
// +build linux,sparc64
|
||||||
|
|
||||||
@ -312,6 +312,17 @@ func Close(fd int) (err error) {
|
|||||||
|
|
||||||
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
|
func CopyFileRange(rfd int, roff *int64, wfd int, woff *int64, len int, flags int) (n int, err error) {
|
||||||
|
r0, _, e1 := Syscall6(SYS_COPY_FILE_RANGE, uintptr(rfd), uintptr(unsafe.Pointer(roff)), uintptr(wfd), uintptr(unsafe.Pointer(woff)), uintptr(len), uintptr(flags))
|
||||||
|
n = int(r0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = errnoErr(e1)
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
// THIS FILE IS GENERATED BY THE COMMAND AT THE TOP; DO NOT EDIT
|
||||||
|
|
||||||
func Dup(oldfd int) (fd int, err error) {
|
func Dup(oldfd int) (fd int, err error) {
|
||||||
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
r0, _, e1 := Syscall(SYS_DUP, uintptr(oldfd), 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
|
101
vendor/golang.org/x/sys/unix/zsyscall_solaris_amd64.go
generated
vendored
101
vendor/golang.org/x/sys/unix/zsyscall_solaris_amd64.go
generated
vendored
@ -1,5 +1,5 @@
|
|||||||
// mksyscall_solaris.pl -tags solaris,amd64 syscall_solaris.go syscall_solaris_amd64.go
|
// mksyscall_solaris.pl -tags solaris,amd64 syscall_solaris.go syscall_solaris_amd64.go
|
||||||
// MACHINE GENERATED BY THE COMMAND ABOVE; DO NOT EDIT
|
// Code generated by the command above; see README.md. DO NOT EDIT.
|
||||||
|
|
||||||
// +build solaris,amd64
|
// +build solaris,amd64
|
||||||
|
|
||||||
@ -22,8 +22,8 @@ import (
|
|||||||
//go:cgo_import_dynamic libc_fcntl fcntl "libc.so"
|
//go:cgo_import_dynamic libc_fcntl fcntl "libc.so"
|
||||||
//go:cgo_import_dynamic libc_futimesat futimesat "libc.so"
|
//go:cgo_import_dynamic libc_futimesat futimesat "libc.so"
|
||||||
//go:cgo_import_dynamic libc_accept accept "libsocket.so"
|
//go:cgo_import_dynamic libc_accept accept "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_recvmsg recvmsg "libsocket.so"
|
//go:cgo_import_dynamic libc___xnet_recvmsg __xnet_recvmsg "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_sendmsg sendmsg "libsocket.so"
|
//go:cgo_import_dynamic libc___xnet_sendmsg __xnet_sendmsg "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_acct acct "libc.so"
|
//go:cgo_import_dynamic libc_acct acct "libc.so"
|
||||||
//go:cgo_import_dynamic libc_ioctl ioctl "libc.so"
|
//go:cgo_import_dynamic libc_ioctl ioctl "libc.so"
|
||||||
//go:cgo_import_dynamic libc_access access "libc.so"
|
//go:cgo_import_dynamic libc_access access "libc.so"
|
||||||
@ -45,6 +45,7 @@ import (
|
|||||||
//go:cgo_import_dynamic libc_fdatasync fdatasync "libc.so"
|
//go:cgo_import_dynamic libc_fdatasync fdatasync "libc.so"
|
||||||
//go:cgo_import_dynamic libc_fpathconf fpathconf "libc.so"
|
//go:cgo_import_dynamic libc_fpathconf fpathconf "libc.so"
|
||||||
//go:cgo_import_dynamic libc_fstat fstat "libc.so"
|
//go:cgo_import_dynamic libc_fstat fstat "libc.so"
|
||||||
|
//go:cgo_import_dynamic libc_fstatvfs fstatvfs "libc.so"
|
||||||
//go:cgo_import_dynamic libc_getdents getdents "libc.so"
|
//go:cgo_import_dynamic libc_getdents getdents "libc.so"
|
||||||
//go:cgo_import_dynamic libc_getgid getgid "libc.so"
|
//go:cgo_import_dynamic libc_getgid getgid "libc.so"
|
||||||
//go:cgo_import_dynamic libc_getpid getpid "libc.so"
|
//go:cgo_import_dynamic libc_getpid getpid "libc.so"
|
||||||
@ -61,7 +62,7 @@ import (
|
|||||||
//go:cgo_import_dynamic libc_kill kill "libc.so"
|
//go:cgo_import_dynamic libc_kill kill "libc.so"
|
||||||
//go:cgo_import_dynamic libc_lchown lchown "libc.so"
|
//go:cgo_import_dynamic libc_lchown lchown "libc.so"
|
||||||
//go:cgo_import_dynamic libc_link link "libc.so"
|
//go:cgo_import_dynamic libc_link link "libc.so"
|
||||||
//go:cgo_import_dynamic libc_listen listen "libsocket.so"
|
//go:cgo_import_dynamic libc___xnet_llisten __xnet_llisten "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_lstat lstat "libc.so"
|
//go:cgo_import_dynamic libc_lstat lstat "libc.so"
|
||||||
//go:cgo_import_dynamic libc_madvise madvise "libc.so"
|
//go:cgo_import_dynamic libc_madvise madvise "libc.so"
|
||||||
//go:cgo_import_dynamic libc_mkdir mkdir "libc.so"
|
//go:cgo_import_dynamic libc_mkdir mkdir "libc.so"
|
||||||
@ -101,6 +102,7 @@ import (
|
|||||||
//go:cgo_import_dynamic libc_setuid setuid "libc.so"
|
//go:cgo_import_dynamic libc_setuid setuid "libc.so"
|
||||||
//go:cgo_import_dynamic libc_shutdown shutdown "libsocket.so"
|
//go:cgo_import_dynamic libc_shutdown shutdown "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_stat stat "libc.so"
|
//go:cgo_import_dynamic libc_stat stat "libc.so"
|
||||||
|
//go:cgo_import_dynamic libc_statvfs statvfs "libc.so"
|
||||||
//go:cgo_import_dynamic libc_symlink symlink "libc.so"
|
//go:cgo_import_dynamic libc_symlink symlink "libc.so"
|
||||||
//go:cgo_import_dynamic libc_sync sync "libc.so"
|
//go:cgo_import_dynamic libc_sync sync "libc.so"
|
||||||
//go:cgo_import_dynamic libc_times times "libc.so"
|
//go:cgo_import_dynamic libc_times times "libc.so"
|
||||||
@ -114,15 +116,15 @@ import (
|
|||||||
//go:cgo_import_dynamic libc_unlinkat unlinkat "libc.so"
|
//go:cgo_import_dynamic libc_unlinkat unlinkat "libc.so"
|
||||||
//go:cgo_import_dynamic libc_ustat ustat "libc.so"
|
//go:cgo_import_dynamic libc_ustat ustat "libc.so"
|
||||||
//go:cgo_import_dynamic libc_utime utime "libc.so"
|
//go:cgo_import_dynamic libc_utime utime "libc.so"
|
||||||
//go:cgo_import_dynamic libc_bind bind "libsocket.so"
|
//go:cgo_import_dynamic libc___xnet_bind __xnet_bind "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_connect connect "libsocket.so"
|
//go:cgo_import_dynamic libc___xnet_connect __xnet_connect "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_mmap mmap "libc.so"
|
//go:cgo_import_dynamic libc_mmap mmap "libc.so"
|
||||||
//go:cgo_import_dynamic libc_munmap munmap "libc.so"
|
//go:cgo_import_dynamic libc_munmap munmap "libc.so"
|
||||||
//go:cgo_import_dynamic libc_sendto sendto "libsocket.so"
|
//go:cgo_import_dynamic libc___xnet_sendto __xnet_sendto "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_socket socket "libsocket.so"
|
//go:cgo_import_dynamic libc___xnet_socket __xnet_socket "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_socketpair socketpair "libsocket.so"
|
//go:cgo_import_dynamic libc___xnet_socketpair __xnet_socketpair "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_write write "libc.so"
|
//go:cgo_import_dynamic libc_write write "libc.so"
|
||||||
//go:cgo_import_dynamic libc_getsockopt getsockopt "libsocket.so"
|
//go:cgo_import_dynamic libc___xnet_getsockopt __xnet_getsockopt "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_getpeername getpeername "libsocket.so"
|
//go:cgo_import_dynamic libc_getpeername getpeername "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_setsockopt setsockopt "libsocket.so"
|
//go:cgo_import_dynamic libc_setsockopt setsockopt "libsocket.so"
|
||||||
//go:cgo_import_dynamic libc_recvfrom recvfrom "libsocket.so"
|
//go:cgo_import_dynamic libc_recvfrom recvfrom "libsocket.so"
|
||||||
@ -140,8 +142,8 @@ import (
|
|||||||
//go:linkname procfcntl libc_fcntl
|
//go:linkname procfcntl libc_fcntl
|
||||||
//go:linkname procfutimesat libc_futimesat
|
//go:linkname procfutimesat libc_futimesat
|
||||||
//go:linkname procaccept libc_accept
|
//go:linkname procaccept libc_accept
|
||||||
//go:linkname procrecvmsg libc_recvmsg
|
//go:linkname proc__xnet_recvmsg libc___xnet_recvmsg
|
||||||
//go:linkname procsendmsg libc_sendmsg
|
//go:linkname proc__xnet_sendmsg libc___xnet_sendmsg
|
||||||
//go:linkname procacct libc_acct
|
//go:linkname procacct libc_acct
|
||||||
//go:linkname procioctl libc_ioctl
|
//go:linkname procioctl libc_ioctl
|
||||||
//go:linkname procAccess libc_access
|
//go:linkname procAccess libc_access
|
||||||
@ -163,6 +165,7 @@ import (
|
|||||||
//go:linkname procFdatasync libc_fdatasync
|
//go:linkname procFdatasync libc_fdatasync
|
||||||
//go:linkname procFpathconf libc_fpathconf
|
//go:linkname procFpathconf libc_fpathconf
|
||||||
//go:linkname procFstat libc_fstat
|
//go:linkname procFstat libc_fstat
|
||||||
|
//go:linkname procFstatvfs libc_fstatvfs
|
||||||
//go:linkname procGetdents libc_getdents
|
//go:linkname procGetdents libc_getdents
|
||||||
//go:linkname procGetgid libc_getgid
|
//go:linkname procGetgid libc_getgid
|
||||||
//go:linkname procGetpid libc_getpid
|
//go:linkname procGetpid libc_getpid
|
||||||
@ -179,7 +182,7 @@ import (
|
|||||||
//go:linkname procKill libc_kill
|
//go:linkname procKill libc_kill
|
||||||
//go:linkname procLchown libc_lchown
|
//go:linkname procLchown libc_lchown
|
||||||
//go:linkname procLink libc_link
|
//go:linkname procLink libc_link
|
||||||
//go:linkname proclisten libc_listen
|
//go:linkname proc__xnet_llisten libc___xnet_llisten
|
||||||
//go:linkname procLstat libc_lstat
|
//go:linkname procLstat libc_lstat
|
||||||
//go:linkname procMadvise libc_madvise
|
//go:linkname procMadvise libc_madvise
|
||||||
//go:linkname procMkdir libc_mkdir
|
//go:linkname procMkdir libc_mkdir
|
||||||
@ -219,6 +222,7 @@ import (
|
|||||||
//go:linkname procSetuid libc_setuid
|
//go:linkname procSetuid libc_setuid
|
||||||
//go:linkname procshutdown libc_shutdown
|
//go:linkname procshutdown libc_shutdown
|
||||||
//go:linkname procStat libc_stat
|
//go:linkname procStat libc_stat
|
||||||
|
//go:linkname procStatvfs libc_statvfs
|
||||||
//go:linkname procSymlink libc_symlink
|
//go:linkname procSymlink libc_symlink
|
||||||
//go:linkname procSync libc_sync
|
//go:linkname procSync libc_sync
|
||||||
//go:linkname procTimes libc_times
|
//go:linkname procTimes libc_times
|
||||||
@ -232,15 +236,15 @@ import (
|
|||||||
//go:linkname procUnlinkat libc_unlinkat
|
//go:linkname procUnlinkat libc_unlinkat
|
||||||
//go:linkname procUstat libc_ustat
|
//go:linkname procUstat libc_ustat
|
||||||
//go:linkname procUtime libc_utime
|
//go:linkname procUtime libc_utime
|
||||||
//go:linkname procbind libc_bind
|
//go:linkname proc__xnet_bind libc___xnet_bind
|
||||||
//go:linkname procconnect libc_connect
|
//go:linkname proc__xnet_connect libc___xnet_connect
|
||||||
//go:linkname procmmap libc_mmap
|
//go:linkname procmmap libc_mmap
|
||||||
//go:linkname procmunmap libc_munmap
|
//go:linkname procmunmap libc_munmap
|
||||||
//go:linkname procsendto libc_sendto
|
//go:linkname proc__xnet_sendto libc___xnet_sendto
|
||||||
//go:linkname procsocket libc_socket
|
//go:linkname proc__xnet_socket libc___xnet_socket
|
||||||
//go:linkname procsocketpair libc_socketpair
|
//go:linkname proc__xnet_socketpair libc___xnet_socketpair
|
||||||
//go:linkname procwrite libc_write
|
//go:linkname procwrite libc_write
|
||||||
//go:linkname procgetsockopt libc_getsockopt
|
//go:linkname proc__xnet_getsockopt libc___xnet_getsockopt
|
||||||
//go:linkname procgetpeername libc_getpeername
|
//go:linkname procgetpeername libc_getpeername
|
||||||
//go:linkname procsetsockopt libc_setsockopt
|
//go:linkname procsetsockopt libc_setsockopt
|
||||||
//go:linkname procrecvfrom libc_recvfrom
|
//go:linkname procrecvfrom libc_recvfrom
|
||||||
@ -259,8 +263,8 @@ var (
|
|||||||
procfcntl,
|
procfcntl,
|
||||||
procfutimesat,
|
procfutimesat,
|
||||||
procaccept,
|
procaccept,
|
||||||
procrecvmsg,
|
proc__xnet_recvmsg,
|
||||||
procsendmsg,
|
proc__xnet_sendmsg,
|
||||||
procacct,
|
procacct,
|
||||||
procioctl,
|
procioctl,
|
||||||
procAccess,
|
procAccess,
|
||||||
@ -282,6 +286,7 @@ var (
|
|||||||
procFdatasync,
|
procFdatasync,
|
||||||
procFpathconf,
|
procFpathconf,
|
||||||
procFstat,
|
procFstat,
|
||||||
|
procFstatvfs,
|
||||||
procGetdents,
|
procGetdents,
|
||||||
procGetgid,
|
procGetgid,
|
||||||
procGetpid,
|
procGetpid,
|
||||||
@ -298,7 +303,7 @@ var (
|
|||||||
procKill,
|
procKill,
|
||||||
procLchown,
|
procLchown,
|
||||||
procLink,
|
procLink,
|
||||||
proclisten,
|
proc__xnet_llisten,
|
||||||
procLstat,
|
procLstat,
|
||||||
procMadvise,
|
procMadvise,
|
||||||
procMkdir,
|
procMkdir,
|
||||||
@ -338,6 +343,7 @@ var (
|
|||||||
procSetuid,
|
procSetuid,
|
||||||
procshutdown,
|
procshutdown,
|
||||||
procStat,
|
procStat,
|
||||||
|
procStatvfs,
|
||||||
procSymlink,
|
procSymlink,
|
||||||
procSync,
|
procSync,
|
||||||
procTimes,
|
procTimes,
|
||||||
@ -351,15 +357,15 @@ var (
|
|||||||
procUnlinkat,
|
procUnlinkat,
|
||||||
procUstat,
|
procUstat,
|
||||||
procUtime,
|
procUtime,
|
||||||
procbind,
|
proc__xnet_bind,
|
||||||
procconnect,
|
proc__xnet_connect,
|
||||||
procmmap,
|
procmmap,
|
||||||
procmunmap,
|
procmunmap,
|
||||||
procsendto,
|
proc__xnet_sendto,
|
||||||
procsocket,
|
proc__xnet_socket,
|
||||||
procsocketpair,
|
proc__xnet_socketpair,
|
||||||
procwrite,
|
procwrite,
|
||||||
procgetsockopt,
|
proc__xnet_getsockopt,
|
||||||
procgetpeername,
|
procgetpeername,
|
||||||
procsetsockopt,
|
procsetsockopt,
|
||||||
procrecvfrom,
|
procrecvfrom,
|
||||||
@ -488,7 +494,7 @@ func accept(s int, rsa *RawSockaddrAny, addrlen *_Socklen) (fd int, err error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func recvmsg(s int, msg *Msghdr, flags int) (n int, err error) {
|
func recvmsg(s int, msg *Msghdr, flags int) (n int, err error) {
|
||||||
r0, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&procrecvmsg)), 3, uintptr(s), uintptr(unsafe.Pointer(msg)), uintptr(flags), 0, 0, 0)
|
r0, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&proc__xnet_recvmsg)), 3, uintptr(s), uintptr(unsafe.Pointer(msg)), uintptr(flags), 0, 0, 0)
|
||||||
n = int(r0)
|
n = int(r0)
|
||||||
if e1 != 0 {
|
if e1 != 0 {
|
||||||
err = e1
|
err = e1
|
||||||
@ -497,7 +503,7 @@ func recvmsg(s int, msg *Msghdr, flags int) (n int, err error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func sendmsg(s int, msg *Msghdr, flags int) (n int, err error) {
|
func sendmsg(s int, msg *Msghdr, flags int) (n int, err error) {
|
||||||
r0, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&procsendmsg)), 3, uintptr(s), uintptr(unsafe.Pointer(msg)), uintptr(flags), 0, 0, 0)
|
r0, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&proc__xnet_sendmsg)), 3, uintptr(s), uintptr(unsafe.Pointer(msg)), uintptr(flags), 0, 0, 0)
|
||||||
n = int(r0)
|
n = int(r0)
|
||||||
if e1 != 0 {
|
if e1 != 0 {
|
||||||
err = e1
|
err = e1
|
||||||
@ -713,6 +719,14 @@ func Fstat(fd int, stat *Stat_t) (err error) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func Fstatvfs(fd int, vfsstat *Statvfs_t) (err error) {
|
||||||
|
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&procFstatvfs)), 2, uintptr(fd), uintptr(unsafe.Pointer(vfsstat)), 0, 0, 0, 0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = e1
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
func Getdents(fd int, buf []byte, basep *uintptr) (n int, err error) {
|
func Getdents(fd int, buf []byte, basep *uintptr) (n int, err error) {
|
||||||
var _p0 *byte
|
var _p0 *byte
|
||||||
if len(buf) > 0 {
|
if len(buf) > 0 {
|
||||||
@ -853,7 +867,7 @@ func Link(path string, link string) (err error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func Listen(s int, backlog int) (err error) {
|
func Listen(s int, backlog int) (err error) {
|
||||||
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&proclisten)), 2, uintptr(s), uintptr(backlog), 0, 0, 0, 0)
|
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&proc__xnet_llisten)), 2, uintptr(s), uintptr(backlog), 0, 0, 0, 0)
|
||||||
if e1 != 0 {
|
if e1 != 0 {
|
||||||
err = e1
|
err = e1
|
||||||
}
|
}
|
||||||
@ -1302,6 +1316,19 @@ func Stat(path string, stat *Stat_t) (err error) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func Statvfs(path string, vfsstat *Statvfs_t) (err error) {
|
||||||
|
var _p0 *byte
|
||||||
|
_p0, err = BytePtrFromString(path)
|
||||||
|
if err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&procStatvfs)), 2, uintptr(unsafe.Pointer(_p0)), uintptr(unsafe.Pointer(vfsstat)), 0, 0, 0, 0)
|
||||||
|
if e1 != 0 {
|
||||||
|
err = e1
|
||||||
|
}
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
func Symlink(path string, link string) (err error) {
|
func Symlink(path string, link string) (err error) {
|
||||||
var _p0 *byte
|
var _p0 *byte
|
||||||
_p0, err = BytePtrFromString(path)
|
_p0, err = BytePtrFromString(path)
|
||||||
@ -1441,7 +1468,7 @@ func Utime(path string, buf *Utimbuf) (err error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func bind(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) {
|
func bind(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) {
|
||||||
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&procbind)), 3, uintptr(s), uintptr(addr), uintptr(addrlen), 0, 0, 0)
|
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&proc__xnet_bind)), 3, uintptr(s), uintptr(addr), uintptr(addrlen), 0, 0, 0)
|
||||||
if e1 != 0 {
|
if e1 != 0 {
|
||||||
err = e1
|
err = e1
|
||||||
}
|
}
|
||||||
@ -1449,7 +1476,7 @@ func bind(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func connect(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) {
|
func connect(s int, addr unsafe.Pointer, addrlen _Socklen) (err error) {
|
||||||
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&procconnect)), 3, uintptr(s), uintptr(addr), uintptr(addrlen), 0, 0, 0)
|
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&proc__xnet_connect)), 3, uintptr(s), uintptr(addr), uintptr(addrlen), 0, 0, 0)
|
||||||
if e1 != 0 {
|
if e1 != 0 {
|
||||||
err = e1
|
err = e1
|
||||||
}
|
}
|
||||||
@ -1478,7 +1505,7 @@ func sendto(s int, buf []byte, flags int, to unsafe.Pointer, addrlen _Socklen) (
|
|||||||
if len(buf) > 0 {
|
if len(buf) > 0 {
|
||||||
_p0 = &buf[0]
|
_p0 = &buf[0]
|
||||||
}
|
}
|
||||||
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&procsendto)), 6, uintptr(s), uintptr(unsafe.Pointer(_p0)), uintptr(len(buf)), uintptr(flags), uintptr(to), uintptr(addrlen))
|
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&proc__xnet_sendto)), 6, uintptr(s), uintptr(unsafe.Pointer(_p0)), uintptr(len(buf)), uintptr(flags), uintptr(to), uintptr(addrlen))
|
||||||
if e1 != 0 {
|
if e1 != 0 {
|
||||||
err = e1
|
err = e1
|
||||||
}
|
}
|
||||||
@ -1486,7 +1513,7 @@ func sendto(s int, buf []byte, flags int, to unsafe.Pointer, addrlen _Socklen) (
|
|||||||
}
|
}
|
||||||
|
|
||||||
func socket(domain int, typ int, proto int) (fd int, err error) {
|
func socket(domain int, typ int, proto int) (fd int, err error) {
|
||||||
r0, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&procsocket)), 3, uintptr(domain), uintptr(typ), uintptr(proto), 0, 0, 0)
|
r0, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&proc__xnet_socket)), 3, uintptr(domain), uintptr(typ), uintptr(proto), 0, 0, 0)
|
||||||
fd = int(r0)
|
fd = int(r0)
|
||||||
if e1 != 0 {
|
if e1 != 0 {
|
||||||
err = e1
|
err = e1
|
||||||
@ -1495,7 +1522,7 @@ func socket(domain int, typ int, proto int) (fd int, err error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func socketpair(domain int, typ int, proto int, fd *[2]int32) (err error) {
|
func socketpair(domain int, typ int, proto int, fd *[2]int32) (err error) {
|
||||||
_, _, e1 := rawSysvicall6(uintptr(unsafe.Pointer(&procsocketpair)), 4, uintptr(domain), uintptr(typ), uintptr(proto), uintptr(unsafe.Pointer(fd)), 0, 0)
|
_, _, e1 := rawSysvicall6(uintptr(unsafe.Pointer(&proc__xnet_socketpair)), 4, uintptr(domain), uintptr(typ), uintptr(proto), uintptr(unsafe.Pointer(fd)), 0, 0)
|
||||||
if e1 != 0 {
|
if e1 != 0 {
|
||||||
err = e1
|
err = e1
|
||||||
}
|
}
|
||||||
@ -1516,7 +1543,7 @@ func write(fd int, p []byte) (n int, err error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func getsockopt(s int, level int, name int, val unsafe.Pointer, vallen *_Socklen) (err error) {
|
func getsockopt(s int, level int, name int, val unsafe.Pointer, vallen *_Socklen) (err error) {
|
||||||
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&procgetsockopt)), 5, uintptr(s), uintptr(level), uintptr(name), uintptr(val), uintptr(unsafe.Pointer(vallen)), 0)
|
_, _, e1 := sysvicall6(uintptr(unsafe.Pointer(&proc__xnet_getsockopt)), 5, uintptr(s), uintptr(level), uintptr(name), uintptr(val), uintptr(unsafe.Pointer(vallen)), 0)
|
||||||
if e1 != 0 {
|
if e1 != 0 {
|
||||||
err = e1
|
err = e1
|
||||||
}
|
}
|
||||||
|
18
vendor/golang.org/x/sys/unix/ztypes_linux_mips.go
generated
vendored
18
vendor/golang.org/x/sys/unix/ztypes_linux_mips.go
generated
vendored
@ -568,17 +568,13 @@ type InotifyEvent struct {
|
|||||||
const SizeofInotifyEvent = 0x10
|
const SizeofInotifyEvent = 0x10
|
||||||
|
|
||||||
type PtraceRegs struct {
|
type PtraceRegs struct {
|
||||||
Regs [109]uint32
|
Regs [32]uint64
|
||||||
U_tsize uint32
|
Lo uint64
|
||||||
U_dsize uint32
|
Hi uint64
|
||||||
U_ssize uint32
|
Epc uint64
|
||||||
Start_code uint32
|
Badvaddr uint64
|
||||||
Start_data uint32
|
Status uint64
|
||||||
Start_stack uint32
|
Cause uint64
|
||||||
Signal int32
|
|
||||||
U_ar0 *byte
|
|
||||||
Magic uint32
|
|
||||||
U_comm [32]int8
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type FdSet struct {
|
type FdSet struct {
|
||||||
|
18
vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go
generated
vendored
18
vendor/golang.org/x/sys/unix/ztypes_linux_mips64.go
generated
vendored
@ -570,17 +570,13 @@ type InotifyEvent struct {
|
|||||||
const SizeofInotifyEvent = 0x10
|
const SizeofInotifyEvent = 0x10
|
||||||
|
|
||||||
type PtraceRegs struct {
|
type PtraceRegs struct {
|
||||||
Regs [102]uint64
|
Regs [32]uint64
|
||||||
U_tsize uint64
|
Lo uint64
|
||||||
U_dsize uint64
|
Hi uint64
|
||||||
U_ssize uint64
|
Epc uint64
|
||||||
Start_code uint64
|
Badvaddr uint64
|
||||||
Start_data uint64
|
Status uint64
|
||||||
Start_stack uint64
|
Cause uint64
|
||||||
Signal int64
|
|
||||||
U_ar0 uint64
|
|
||||||
Magic uint64
|
|
||||||
U_comm [32]int8
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type FdSet struct {
|
type FdSet struct {
|
||||||
|
18
vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go
generated
vendored
18
vendor/golang.org/x/sys/unix/ztypes_linux_mips64le.go
generated
vendored
@ -570,17 +570,13 @@ type InotifyEvent struct {
|
|||||||
const SizeofInotifyEvent = 0x10
|
const SizeofInotifyEvent = 0x10
|
||||||
|
|
||||||
type PtraceRegs struct {
|
type PtraceRegs struct {
|
||||||
Regs [102]uint64
|
Regs [32]uint64
|
||||||
U_tsize uint64
|
Lo uint64
|
||||||
U_dsize uint64
|
Hi uint64
|
||||||
U_ssize uint64
|
Epc uint64
|
||||||
Start_code uint64
|
Badvaddr uint64
|
||||||
Start_data uint64
|
Status uint64
|
||||||
Start_stack uint64
|
Cause uint64
|
||||||
Signal int64
|
|
||||||
U_ar0 uint64
|
|
||||||
Magic uint64
|
|
||||||
U_comm [32]int8
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type FdSet struct {
|
type FdSet struct {
|
||||||
|
18
vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go
generated
vendored
18
vendor/golang.org/x/sys/unix/ztypes_linux_mipsle.go
generated
vendored
@ -568,17 +568,13 @@ type InotifyEvent struct {
|
|||||||
const SizeofInotifyEvent = 0x10
|
const SizeofInotifyEvent = 0x10
|
||||||
|
|
||||||
type PtraceRegs struct {
|
type PtraceRegs struct {
|
||||||
Regs [109]uint32
|
Regs [32]uint64
|
||||||
U_tsize uint32
|
Lo uint64
|
||||||
U_dsize uint32
|
Hi uint64
|
||||||
U_ssize uint32
|
Epc uint64
|
||||||
Start_code uint32
|
Badvaddr uint64
|
||||||
Start_data uint32
|
Status uint64
|
||||||
Start_stack uint32
|
Cause uint64
|
||||||
Signal int32
|
|
||||||
U_ar0 *byte
|
|
||||||
Magic uint32
|
|
||||||
U_comm [32]int8
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type FdSet struct {
|
type FdSet struct {
|
||||||
|
23
vendor/golang.org/x/sys/unix/ztypes_solaris_amd64.go
generated
vendored
23
vendor/golang.org/x/sys/unix/ztypes_solaris_amd64.go
generated
vendored
@ -1,6 +1,7 @@
|
|||||||
// +build amd64,solaris
|
|
||||||
// Created by cgo -godefs - DO NOT EDIT
|
|
||||||
// cgo -godefs types_solaris.go | go run mkpost.go
|
// cgo -godefs types_solaris.go | go run mkpost.go
|
||||||
|
// Code generated by the command above; see README.md. DO NOT EDIT.
|
||||||
|
|
||||||
|
// +build amd64,solaris
|
||||||
|
|
||||||
package unix
|
package unix
|
||||||
|
|
||||||
@ -128,6 +129,24 @@ type Dirent struct {
|
|||||||
Pad_cgo_0 [5]byte
|
Pad_cgo_0 [5]byte
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type _Fsblkcnt_t uint64
|
||||||
|
|
||||||
|
type Statvfs_t struct {
|
||||||
|
Bsize uint64
|
||||||
|
Frsize uint64
|
||||||
|
Blocks uint64
|
||||||
|
Bfree uint64
|
||||||
|
Bavail uint64
|
||||||
|
Files uint64
|
||||||
|
Ffree uint64
|
||||||
|
Favail uint64
|
||||||
|
Fsid uint64
|
||||||
|
Basetype [16]int8
|
||||||
|
Flag uint64
|
||||||
|
Namemax uint64
|
||||||
|
Fstr [32]int8
|
||||||
|
}
|
||||||
|
|
||||||
type RawSockaddrInet4 struct {
|
type RawSockaddrInet4 struct {
|
||||||
Family uint16
|
Family uint16
|
||||||
Port uint16
|
Port uint16
|
||||||
|
Loading…
Reference in New Issue
Block a user