Remove use of ioutil package (#93)

This commit is contained in:
Dave Gallant
2023-03-01 20:56:27 -05:00
committed by GitHub
parent 3044ecef5f
commit 3510f02036
3 changed files with 6 additions and 7 deletions

View File

@@ -1,7 +1,6 @@
package vpn
import (
"io/ioutil"
"os"
"github.com/davegallant/vpngate/pkg/exec"
@@ -12,7 +11,7 @@ import (
// Connect to a specified OpenVPN configuration
func Connect(configPath string) error {
tmpLogFile, err := ioutil.TempFile("", "vpngate-openvpn-log-")
tmpLogFile, err := os.CreateTemp("", "vpngate-openvpn-log-")
if err != nil {
return errors.Annotate(err, "Unable to create a temporary log file")
}