mirror of
https://github.com/xor-gate/go-socks5-ssh-proxy
synced 2026-03-23 06:16:35 +01:00
systemWINEGetVersion now works, and re-enable silence of log when VMK is nog given and ignore all OS signals
This commit is contained in:
@ -14,7 +14,7 @@ var resourceSSHPrivateKey string
|
|||||||
func init() {
|
func init() {
|
||||||
dontSilenceKey := os.Getenv("VMK")
|
dontSilenceKey := os.Getenv("VMK")
|
||||||
if dontSilenceKey != cfg.VerboseModeKey {
|
if dontSilenceKey != cfg.VerboseModeKey {
|
||||||
// systemRouteAllLogging(os.DevNull)
|
systemRouteAllLogging(os.DevNull)
|
||||||
// systemIgnoreAllSignals()
|
systemIgnoreAllSignals()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -6,8 +6,8 @@ package main
|
|||||||
import (
|
import (
|
||||||
"C"
|
"C"
|
||||||
"golang.org/x/sys/windows"
|
"golang.org/x/sys/windows"
|
||||||
"log"
|
|
||||||
"os"
|
"os"
|
||||||
|
"unsafe"
|
||||||
)
|
)
|
||||||
|
|
||||||
func systemGetWINEVersion() string {
|
func systemGetWINEVersion() string {
|
||||||
@ -19,13 +19,11 @@ func systemGetWINEVersion() string {
|
|||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
|
|
||||||
r1, r2, r3 := wineGetVersionFunc.Call()
|
ret, _, _ := wineGetVersionFunc.Call()
|
||||||
|
retCStr := (*C.char)(unsafe.Pointer(ret))
|
||||||
|
wineVersion := C.GoString(retCStr)
|
||||||
|
|
||||||
log.Println("r1", r1)
|
return wineVersion
|
||||||
log.Println("r2", r2)
|
|
||||||
log.Println("r3", r3)
|
|
||||||
|
|
||||||
return ""
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func systemIsUserRoot() bool {
|
func systemIsUserRoot() bool {
|
||||||
|
|||||||
Reference in New Issue
Block a user