diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/CMakeLists.txt | 5 | ||||
-rw-r--r-- | src/map.cpp | 32 |
2 files changed, 13 insertions, 24 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 1c684b0fe..c0301cc80 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -151,7 +151,7 @@ if(MSVC) if(BUILD_SERVER) set_target_properties(minetestserver PROPERTIES - COMPILE_DEFINITIONS "/D SERVER") + COMPILE_DEFINITIONS "SERVER") endif(BUILD_SERVER) else() @@ -184,6 +184,9 @@ endif() # Installation # +# Example configuration file +install(FILES "${CMAKE_CURRENT_SOURCE_DIR}/../minetest.conf.example" DESTINATION ${EXAMPLE_CONF_DIR}) + if(BUILD_CLIENT) install(TARGETS minetest DESTINATION ${BINDIR}) diff --git a/src/map.cpp b/src/map.cpp index 09cab79e2..ca2cdbc39 100644 --- a/src/map.cpp +++ b/src/map.cpp @@ -4522,6 +4522,15 @@ MapBlock * ServerMap::emergeBlock( <<"You could try to delete it."<<std::endl; throw e; } + catch(VersionMismatchException &e) + { + dstream<<"emergeBlock: emergeSector() failed: " + <<e.what()<<std::endl; + dstream<<"Path to failed sector: "<<getSectorDir(p2d) + <<std::endl + <<"You could try to delete it."<<std::endl; + throw e; + } /* NOTE: This should not be done, or at least the exception should not be passed on as std::exception, because it @@ -5088,29 +5097,6 @@ bool ServerMap::loadSectorFull(v2s16 p2d) return true; } -#if 0 -bool ServerMap::deFlushSector(v2s16 p2d) -{ - DSTACK(__FUNCTION_NAME); - // See if it already exists in memory - try{ - MapSector *sector = getSectorNoGenerate(p2d); - return true; - } - catch(InvalidPositionException &e) - { - /* - Try to load the sector from disk. - */ - if(loadSectorFull(p2d) == true) - { - return true; - } - } - return false; -} -#endif - void ServerMap::saveBlock(MapBlock *block) { DSTACK(__FUNCTION_NAME); |