From 50b0e9f7a4916044b1938d461c9c4029b30569da Mon Sep 17 00:00:00 2001 From: kwolekr Date: Sun, 8 Dec 2013 22:13:05 -0500 Subject: [PATCH] Mapgen Indev: Fix segfault in cave generation due to uninitialized variable --- src/mapgen_indev.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/mapgen_indev.cpp b/src/mapgen_indev.cpp index 7203fc85..a22e2522 100644 --- a/src/mapgen_indev.cpp +++ b/src/mapgen_indev.cpp @@ -274,7 +274,9 @@ void MapgenIndev::generateCaves(int max_stone_y) { CaveIndev::CaveIndev(MapgenIndev *mg, PseudoRandom *ps, PseudoRandom *ps2, v3s16 node_min, bool is_large_cave) { + this->mg = mg; this->vm = mg->vm; + this->ndef = mg->ndef; this->water_level = mg->water_level; this->large_cave = is_large_cave; this->ps = ps; -- 2.30.2