stujones11 / minetest-3d_armor

Visible player armor & wielded items for minetest
Other
55 stars 97 forks source link

Server error: attempt to index local 'armor_inv' (a nil value) #21

Closed Calinou closed 9 years ago

Calinou commented 9 years ago
2015-04-01 04:56:05: ERROR[main]: UNRECOVERABLE error occurred. Stopping server. Please fix the following error:
2015-04-01 04:56:05: ERROR[main]: ...home/hugo/.minetest/mods/3d_armor/3d_armor/armor.lua:477: attempt to index local 'armor_inv' (a nil value)
2015-04-01 04:56:05: ERROR[main]: stack traceback:
2015-04-01 04:56:05: ERROR[main]:       ...home/hugo/.minetest/mods/3d_armor/3d_armor/armor.lua:477: in function '?'
2015-04-01 04:56:05: ERROR[main]:       /home/hugo/minetest/bin/../builtin/game/register.lua:341: in function </home/hugo/minetest/bin/../builtin/game/register.lua:329>

In thread 7fd9068fe740:
/home/hugo/minetest/src/server.cpp:492: void Server::step(float): A fatal error occurred: ...home/hugo/.minetest/mods/3d_armor/3d_armor/armor.lua:477: attempt to index local 'armor_inv' (a nil value)
stack traceback:
        ...home/hugo/.minetest/mods/3d_armor/3d_armor/armor.lua:477: in function '?'
        /home/hugo/minetest/bin/../builtin/game/register.lua:341: in function </home/hugo/minetest/bin/../builtin/game/register.lua:329>
Debug stacks:
DEBUG STACK FOR THREAD 7fd8f96a7700:
#0  virtual void* EmergeThread::Thread()
(Leftover data: #1  MapBlock* ServerMap::loadBlock(v3s16))
(Leftover data: #2  void ServerMap::loadBlock(std::string*, v3s16, MapSector*, bool))
(Leftover data: #3  void ItemStack::deSerialize(std::istream&, IItemDefManager*))
DEBUG STACK FOR THREAD 7fd8fa0a8700:
#0  virtual void* CurlFetchThread::Thread()
DEBUG STACK FOR THREAD 7fd8faaa9700:
#0  virtual void* ServerThread::Thread()
#1  void Server::Receive()
(Leftover data: #2  void Server::SendBlocks(float))
(Leftover data: #3  void Server::DiePlayer(irr::u16))
(Leftover data: #4  void Server::UpdateCrafting(Player*))
(Leftover data: #5  bool getCraftingResult(Inventory*, ItemStack&, bool, IGameDef*))
(Leftover data: #6  void ItemStack::deSerialize(std::istream&, IItemDefManager*))
DEBUG STACK FOR THREAD 7fd9068fe740:
#0  int main(int, char**)
#1  Dedicated server branch
#2  void dedicated_server_loop(Server&, bool&)
#3  void Server::step(float)
Aborted
stujones11 commented 9 years ago

That's a new one, I am seeing a lot more errors like this recently (nil player objects, inventories etc) I suspect these could be related to the recent network changes in core. All I can really do is add yet another error trap in there to prevent the crash.

Thank you for the report.