projects
/
zefram
/
minetest
/
minetest_engine.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
046534e
)
Don't re-write entire map_meta.txt if a setting is missing
author
kwolekr
<kwolekr@minetest.net>
Sat, 6 Apr 2013 17:36:31 +0000
(13:36 -0400)
committer
kwolekr
<kwolekr@minetest.net>
Sat, 6 Apr 2013 17:36:51 +0000
(13:36 -0400)
src/map.cpp
patch
|
blob
|
history
diff --git
a/src/map.cpp
b/src/map.cpp
index 39f5e30fbef8e32de3b3cc5076e9b3dc162c29bd..c9f473dc2cb150b9c8d39b24fa85d1b905067f21 100644
(file)
--- a/
src/map.cpp
+++ b/
src/map.cpp
@@
-3466,8
+3466,16
@@
void ServerMap::loadMapMeta()
break;
params.parseConfigLine(line);
}
-
- MapgenParams *mgparams = m_emerge->getParamsFromSettings(¶ms);
+
+ MapgenParams *mgparams;
+ try {
+ mgparams = m_emerge->getParamsFromSettings(¶ms);
+ } catch (SettingNotFoundException &e) {
+ infostream << "Couldn't get a setting from map_meta.txt: "
+ << e.what() << std::endl;
+ mgparams = NULL;
+ }
+
if (mgparams) {
if (m_mgparams)
delete m_mgparams;