File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -131,7 +131,7 @@ class ClientImpl implements IClient
131
131
132
132
/**
133
133
* The receiving queue.
134
- * @var IncomingMessage []
134
+ * @var ResponseMessage []
135
135
*/
136
136
private $ incomingQueue ;
137
137
@@ -250,7 +250,7 @@ protected function getMessages()
250
250
// Read something.
251
251
//$read = @fread($this->socket, 65535);
252
252
$ read = @fread ($ this ->socket , 8192 );
253
- if ($ read === false || @feof ($ this ->socket )) {
253
+ if ($ read === false || ( empty ( $ read ) && @feof ($ this ->socket ) )) {
254
254
throw new ClientException ('Error reading ' );
255
255
}
256
256
$ this ->currentProcessingMessage .= $ read ;
@@ -417,12 +417,12 @@ private function messageToEvent($msg)
417
417
*
418
418
* @todo not suitable for multithreaded applications.
419
419
*
420
- * @return \PAMI\Message\IncomingMessage
420
+ * @return \PAMI\Message\Response\ResponseMessage
421
421
*/
422
422
protected function getRelated (OutgoingMessage $ message )
423
423
{
424
424
$ ret = false ;
425
- $ id = $ message ->getActionID (' ActionID ' );
425
+ $ id = $ message ->getActionID ();
426
426
if (isset ($ this ->incomingQueue [$ id ])) {
427
427
$ response = $ this ->incomingQueue [$ id ];
428
428
if ($ response ->isComplete ()) {
You can’t perform that action at this time.
0 commit comments