1
0

Trap unserialize() fails.

This commit is contained in:
Bharat Mediratta 2012-02-05 17:14:53 -08:00
parent b3b9e76a49
commit c665f476cf

View File

@ -93,7 +93,13 @@ class Admin_Session_Explorer_Controller extends Admin_Controller {
}
$value_text = substr($data, $last_offset);
try {
$return_array[$current_key] = unserialize($value_text);
} catch (ErrorException $e) {
// Dunno why unserialize fails. If it fails enough, it'll show up in the aggregate
// counts and we can deal with it.
return array("user_agent" => "[unserialize fail]", "ip_address" => "[unserialize fail]");
}
return $return_array;
}
}