mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Switch more stuff to use the logging thing and fix segfault on player leave from server as introduced in a previous switch-to-logging commit
This commit is contained in:
parent
67a6bc4ab5
commit
0bf533f753
3 changed files with 13 additions and 10 deletions
|
@ -24,6 +24,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
#include "inventory.h"
|
||||
#include <sstream>
|
||||
#include "content_mapnode.h"
|
||||
#include "log.h"
|
||||
|
||||
/*
|
||||
NodeMetadata
|
||||
|
@ -55,7 +56,7 @@ NodeMetadata* NodeMetadata::deSerialize(std::istream &is)
|
|||
if(n == NULL)
|
||||
{
|
||||
// If factory is not found, just return.
|
||||
dstream<<"WARNING: NodeMetadata: No factory for typeId="
|
||||
infostream<<"WARNING: NodeMetadata: No factory for typeId="
|
||||
<<id<<std::endl;
|
||||
return NULL;
|
||||
}
|
||||
|
@ -71,7 +72,7 @@ NodeMetadata* NodeMetadata::deSerialize(std::istream &is)
|
|||
}
|
||||
catch(SerializationError &e)
|
||||
{
|
||||
dstream<<"WARNING: NodeMetadata: ignoring SerializationError"<<std::endl;
|
||||
infostream<<"WARNING: NodeMetadata: ignoring SerializationError"<<std::endl;
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
|
@ -138,7 +139,7 @@ void NodeMetadataList::deSerialize(std::istream &is)
|
|||
|
||||
if(version > 1)
|
||||
{
|
||||
dstream<<__FUNCTION_NAME<<": version "<<version<<" not supported"
|
||||
infostream<<__FUNCTION_NAME<<": version "<<version<<" not supported"
|
||||
<<std::endl;
|
||||
throw SerializationError("NodeMetadataList::deSerialize");
|
||||
}
|
||||
|
@ -165,7 +166,7 @@ void NodeMetadataList::deSerialize(std::istream &is)
|
|||
|
||||
if(m_data.find(p))
|
||||
{
|
||||
dstream<<"WARNING: NodeMetadataList::deSerialize(): "
|
||||
infostream<<"WARNING: NodeMetadataList::deSerialize(): "
|
||||
<<"already set data at position"
|
||||
<<"("<<p.X<<","<<p.Y<<","<<p.Z<<"): Ignoring."
|
||||
<<std::endl;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue