Cleanup logging

Make sure all logging output is called via the main logger instead of
stdlib `"log"` or `fmt.Print(f|ln)`.

Signed-off-by: SuperQ <superq@gmail.com>
This commit is contained in:
SuperQ
2025-03-01 09:48:13 +01:00
parent c5cec99797
commit 34e33e45bf
14 changed files with 92 additions and 102 deletions

3
usb.go
View File

@@ -2,7 +2,6 @@ package kvm
import (
"kvm/internal/usbgadget"
"log"
"time"
)
@@ -51,7 +50,7 @@ func rpcGetUSBState() (state string) {
func triggerUSBStateUpdate() {
go func() {
if currentSession == nil {
log.Println("No active RPC session, skipping update state update")
logger.Info("No active RPC session, skipping update state update")
return
}
writeJSONRPCEvent("usbState", usbState, currentSession)