Merge pull request #1229 from hashicorp/update-plugin
Updated go-plugin dependency
This commit is contained in:
commit
66fc31ba91
1
vendor/github.com/hashicorp/go-plugin/.gitignore
generated
vendored
1
vendor/github.com/hashicorp/go-plugin/.gitignore
generated
vendored
|
@ -1 +0,0 @@
|
|||
.DS_Store
|
30
vendor/github.com/hashicorp/go-plugin/server.go
generated
vendored
30
vendor/github.com/hashicorp/go-plugin/server.go
generated
vendored
|
@ -183,5 +183,33 @@ func serverListener_unix() (net.Listener, error) {
|
|||
return nil, err
|
||||
}
|
||||
|
||||
return net.Listen("unix", path)
|
||||
l, err := net.Listen("unix", path)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
// Wrap the listener in rmListener so that the Unix domain socket file
|
||||
// is removed on close.
|
||||
return &rmListener{
|
||||
Listener: l,
|
||||
Path: path,
|
||||
}, nil
|
||||
}
|
||||
|
||||
// rmListener is an implementation of net.Listener that forwards most
|
||||
// calls to the listener but also removes a file as part of the close. We
|
||||
// use this to cleanup the unix domain socket on close.
|
||||
type rmListener struct {
|
||||
net.Listener
|
||||
Path string
|
||||
}
|
||||
|
||||
func (l *rmListener) Close() error {
|
||||
// Close the listener itself
|
||||
if err := l.Listener.Close(); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
// Remove the file
|
||||
return os.Remove(l.Path)
|
||||
}
|
||||
|
|
4
vendor/vendor.json
vendored
4
vendor/vendor.json
vendored
|
@ -461,8 +461,10 @@
|
|||
"revision": "d30f09973e19c1dfcd120b2d9c4f168e68d6b5d5"
|
||||
},
|
||||
{
|
||||
"checksumSHA1": "FK7oNTTXthoohAwDgVo/nmf1w9A=",
|
||||
"path": "github.com/hashicorp/go-plugin",
|
||||
"revision": "cccb4a1328abbb89898f3ecf4311a05bddc4de6d"
|
||||
"revision": "6691772c4e872547b2e6cfc54c853a6d61bc0edb",
|
||||
"revisionTime": "2016-06-02T23:01:53Z"
|
||||
},
|
||||
{
|
||||
"path": "github.com/hashicorp/go-syslog",
|
||||
|
|
Loading…
Reference in a new issue