capture some info if serialization fails on stomp frame

This commit is contained in:
Evan Prodromou 2011-04-18 17:55:38 -04:00
parent 21c16b2e92
commit 3fd6b9d474

View File

@ -480,6 +480,13 @@ class StompQueueManager extends QueueManager
{ {
$host = $this->cons[$this->defaultIdx]->getServer(); $host = $this->cons[$this->defaultIdx]->getServer();
$message = unserialize($frame->body); $message = unserialize($frame->body);
if ($message === false) {
$this->_log(LOG_ERR, "Can't unserialize frame: {$frame->body}");
$this->stats('baditem', $queue);
return false;
}
$site = $message['site']; $site = $message['site'];
$queue = $message['handler']; $queue = $message['handler'];