Null all pointers (convert index -> nullptr) */
| 312 | |
| 313 | /** Null all pointers (convert index -> nullptr) */ |
| 314 | static void SlNullPointers() |
| 315 | { |
| 316 | _sl.action = SLA_NULL; |
| 317 | |
| 318 | /* We don't want any savegame conversion code to run |
| 319 | * during NULLing; especially those that try to get |
| 320 | * pointers from other pools. */ |
| 321 | _sl_version = SAVEGAME_VERSION; |
| 322 | |
| 323 | for (const ChunkHandler &ch : ChunkHandlers()) { |
| 324 | Debug(sl, 3, "Nulling pointers for {}", ch.GetName()); |
| 325 | ch.FixPointers(); |
| 326 | } |
| 327 | |
| 328 | assert(_sl.action == SLA_NULL); |
| 329 | } |
| 330 | |
| 331 | /** |
| 332 | * Error handler. Sets everything up to show an error message and to clean |
no test coverage detected