? ? 使用ssl websocket 時(shí), 連續(xù)發(fā)送數(shù)據(jù)時(shí)出現(xiàn)鏈接斷開(kāi)的情況, 查找原因后發(fā)現(xiàn)是TcpConnection 中 baseWrite() 方法中fwrite() 方法在寫(xiě)數(shù)據(jù)時(shí)報(bào)錯(cuò)導(dǎo)致,$len = fwrite($this->_socket, $this->_sendBuffer, 8192);
這段代碼調(diào)用后$len=0; 所以導(dǎo)致鏈接關(guān)閉. 我們服務(wù)器并發(fā)并不高, 大約100人同時(shí)在線, 所以也沒(méi)有裝event擴(kuò)展, 是否和這個(gè)有關(guān)系呢?請(qǐng)求這個(gè)問(wèn)題有什么解決方法嗎?