mirror of
https://github.com/1Panel-dev/1Panel.git
synced 2025-09-12 17:46:20 +08:00
fix: Fix the problem that services exit unexpectedly when the contain… (#8127)
Some checks failed
SonarCloud Scan / SonarCloud (push) Failing after -22s
Some checks failed
SonarCloud Scan / SonarCloud (push) Failing after -22s
This commit is contained in:
parent
51fe02661f
commit
5610c73d67
1 changed files with 5 additions and 0 deletions
|
@ -53,6 +53,11 @@ func (sws *LocalWsSession) handleSlaveEvent(exitCh chan bool) {
|
|||
}
|
||||
|
||||
func (sws *LocalWsSession) masterWrite(data []byte) error {
|
||||
defer func() {
|
||||
if r := recover(); r != nil {
|
||||
global.LOG.Errorf("A panic occurred during write ws message to master, error message: %v", r)
|
||||
}
|
||||
}()
|
||||
sws.writeMutex.Lock()
|
||||
defer sws.writeMutex.Unlock()
|
||||
wsData, err := json.Marshal(WsMsg{
|
||||
|
|
Loading…
Add table
Reference in a new issue