safchain / ethtool

A simple ethtool "like" library for GO
Apache License 2.0
116 stars 69 forks source link

Add Ethtool type #9

Closed lebauce closed 8 years ago

lebauce commented 8 years ago

In every method, a socket is created. When using ethtool inside a namespace, it requires switching to the namespace for every call - as staying inside the namespace is risky in Go. This commit introduces a Ethtool that creates the socket once and reuses it for all the following calls