| 347 | } |
| 348 | |
| 349 | void Object::ReceiveScriptMessage(const std::string &msg) { |
| 350 | receive_depth++; |
| 351 | if (receive_depth > 8) { |
| 352 | LOGW << "Deep stack on receive scripts... message: \"" << msg << "\" count: " << receive_depth << std::endl; |
| 353 | } |
| 354 | if (receive_depth > 32) { |
| 355 | LOGE << "I've gotten recursed 32 times now, assuming we're in a loop, queueing this message instead \"" << msg << "\"" << std::endl; |
| 356 | ReceiveObjectMessage(OBJECT_MSG::QUEUE_SCRIPT, &msg); |
| 357 | } else { |
| 358 | ReceiveObjectMessage(OBJECT_MSG::SCRIPT, &msg); |
| 359 | } |
| 360 | receive_depth--; |
| 361 | } |
| 362 | |
| 363 | void Object::QueueScriptMessage(const std::string &msg) { |
| 364 | ReceiveObjectMessage(OBJECT_MSG::QUEUE_SCRIPT, &msg); |
no outgoing calls
no test coverage detected