As well as implementing vsock.Dial in the (hopefully) obvious way this also logs the errno from calling bind in vsockListen. I decided to keep the existing errors.New construction and add the errno info to the string there rather than just returning the errno object (which is itself a valid Error, since it is actually a syscall.Errno which implements the error interface) since the string contains a bit more useful context. Could change that if desired though.
As well as implementing
vsock.Dial
in the (hopefully) obvious way this also logs the errno from calling bind invsockListen
. I decided to keep the existingerrors.New
construction and add the errno info to the string there rather than just returning the errno object (which is itself a validError
, since it is actually asyscall.Errno
which implements the error interface) since the string contains a bit more useful context. Could change that if desired though.