From 0a9e6834a4d1de5f0bbbcae01dc62b9e626ed790 Mon Sep 17 00:00:00 2001 From: Filip Leonarski Date: Mon, 1 Dec 2025 17:21:01 +0100 Subject: [PATCH] RotationIndexer: Fix error in Finalize() --- image_analysis/RotationIndexer.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/image_analysis/RotationIndexer.cpp b/image_analysis/RotationIndexer.cpp index f1c9794d..9743a42c 100644 --- a/image_analysis/RotationIndexer.cpp +++ b/image_analysis/RotationIndexer.cpp @@ -146,6 +146,8 @@ std::optional RotationIndexer::ProcessImage(int64_t image std::optional RotationIndexer::Finalize(bool retry) { if (!indexed_lattice || retry) TryIndex(); + if (!indexed_lattice) + return std::nullopt; return RotationIndexerResult{ .lattice = indexed_lattice.value(), .search_result = search_result_,