From de6a66851e94180f863aee3f4f4fbd5bb47a2a3e Mon Sep 17 00:00:00 2001 From: "alexey.lysiuk" Date: Thu, 12 Jan 2017 16:24:55 +0200 Subject: [PATCH] Fixed issue with extraction of built GL nodes See https://mantis.zdoom.org/view.php?id=39 --- src/nodebuild_extract.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/nodebuild_extract.cpp b/src/nodebuild_extract.cpp index 11332f049..bdb343449 100644 --- a/src/nodebuild_extract.cpp +++ b/src/nodebuild_extract.cpp @@ -123,7 +123,8 @@ void FNodeBuilder::Extract (node_t *&outNodes, int &nodeCount, if (segs[i].Partner != DWORD_MAX) { - outSegs[i].PartnerSeg = &outSegs[Segs[segs[i].Partner].storedseg]; + const DWORD storedseg = Segs[segs[i].Partner].storedseg; + outSegs[i].PartnerSeg = DWORD_MAX == storedseg ? nullptr : &outSegs[storedseg]; } else {