在此函数中运行 socket_recv 时出现套接字错误:
function readByteXByteSIBmsg() {
$msg = "";
$buf="";
try {
while( $ret=socket_recv($this->kpSocket,$buf,8192,0)){
$msg.=$buf;
if($ret<8192) break;
}
$this->deb_print("KpCore:readByteXByteSIBmsg:READ LOOP TERMINATED");
} catch (Exception $e) {
err_print("KPICore:readByteXByteSIBmsg:Exception on EVENT HANDLER:RECEIVE:\n" . $e);
$this->$KP_ERROR_ID = $this->ERR_SOCKET_TIMEOUT;
}
return $msg;
}
这是错误的文本:
PHP Warning: socket_recv(): unable to read from socket [11]: Resource temporarily unavailable in /home/luca/Documenti/Tesi/M3 Agent Page/lib/KPICore.php on line 236
(第 236 行是调用 socket_recv 的行)