From f36a8e015ebebd426ee2d285c8623da55d50367e Mon Sep 17 00:00:00 2001 From: Kp Date: Sun, 5 Jun 2022 17:44:52 +0000 Subject: [PATCH] Disable collecting segment list in see_object The segment list is written to `hit_data`, but `hit_data` goes out of scope before the segment list is read back. Skip collecting it, since it was effectively write-only on this path. --- similar/main/gauges.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/similar/main/gauges.cpp b/similar/main/gauges.cpp index 2b35ff718..6baa533eb 100644 --- a/similar/main/gauges.cpp +++ b/similar/main/gauges.cpp @@ -3499,7 +3499,7 @@ static int see_object(fvcobjptridx &vcobjptridx, const vcobjptridx_t objnum) fq.p1 = &objnum->pos; fq.rad = 0; fq.thisobjnum = vcobjptridx(Viewer); - fq.flags = FQ_TRANSWALL | FQ_CHECK_OBJS | FQ_GET_SEGLIST; + fq.flags = FQ_TRANSWALL | FQ_CHECK_OBJS; fq.startseg = Viewer->segnum; fq.ignore_obj_list.first = nullptr;