Fix Remote speech stalls after pause and early completion
This commit is contained in:
1 parent
6867d901b2
commit
19b789ef5c
6 files changed
+131
-30
No files matched your search
@@ -47,6 +47,7 @@ type Client struct {
|
||||
mutex sync.Mutex
|
||||
cancelMutex sync.Mutex
|
||||
settingsMutex sync.Mutex
|
||||
notification func(reply) // Speaking mutex owns the active completion handler.
|
||||
}
|
||||
|
||||
type Settings struct {
|
||||
@@ -426,6 +427,9 @@ func (client *Client) readReply() (reply, error) {
|
||||
if err != nil || response.code < 700 || response.code >= 800 {
|
||||
return response, err
|
||||
}
|
||||
if client.notification != nil {
|
||||
client.notification(response)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user