Browse Source

Fix bug: handling error with UUID package version updated.

zry 3 years ago
parent
commit
d3616fc8cc
2 changed files with 2 additions and 2 deletions
  1. 1 1
      golang/sipc_conn/server_unix.go
  2. 1 1
      golang/sipc_conn/server_windows.go

+ 1 - 1
golang/sipc_conn/server_unix.go

@@ -14,7 +14,7 @@ type ServerCtx struct {
 }
 
 func GenerateServerName() string {
-	return fmt.Sprintf("satoripc-%s.sock", uuid.NewV4().String())
+	return fmt.Sprintf("satoripc-%s.sock", uuid.Must(uuid.NewV4()).String())
 }
 
 func GeneratePath() string {

+ 1 - 1
golang/sipc_conn/server_windows.go

@@ -15,7 +15,7 @@ type ServerCtx struct {
 }
 
 func GenerateServerName() string {
-	return fmt.Sprintf("satoripc-%s", uuid.NewV4().String())
+	return fmt.Sprintf("satoripc-%s", uuid.Must(uuid.NewV4()).String())
 }
 
 func GeneratePath() string {