| 1494 | |
| 1495 | |
| 1496 | void handleMsgSetVars(void* msg) { |
| 1497 | uint16_t numVars; |
| 1498 | std::string name; |
| 1499 | std::string value; |
| 1500 | |
| 1501 | msg = nboUnpackUInt16(msg, numVars); |
| 1502 | for (int i = 0; i < numVars; i++) { |
| 1503 | msg = nboUnpackStdString(msg, name); |
| 1504 | msg = nboUnpackStdString(msg, value); |
| 1505 | |
| 1506 | if (!name.empty() && ((name[0] == '_') || (name[0] == '$'))) { |
| 1507 | BZDB.set(name, value); |
| 1508 | BZDB.setPersistent(name, false); |
| 1509 | BZDB.setPermission(name, StateDatabase::Locked); |
| 1510 | } |
| 1511 | else { |
| 1512 | debugf(1, "Server BZDB change blocked: '%s' = '%s'\n", |
| 1513 | name.c_str(), value.c_str()); |
| 1514 | } |
| 1515 | } |
| 1516 | } |
| 1517 | |
| 1518 | |
| 1519 | void handleReplayReset(void* msg, bool& checkScores) { |
no test coverage detected