summaryrefslogtreecommitdiff
path: root/src/map.c
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2023-01-29 16:17:51 +0100
committerJörg Frings-Fürst <debian@jff-webhosting.net>2023-01-29 16:17:51 +0100
commitbfef0924f58eab930bdd826ac0132786abc32220 (patch)
treec37bbc77063f3477236ce4cb7d765794f2018555 /src/map.c
parent8132c809273676b684f426ae8c0f8b1e6f40166e (diff)
New upstream version 4.10upstream/4.10
Diffstat (limited to 'src/map.c')
-rw-r--r--src/map.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/map.c b/src/map.c
index a90a731..40f376c 100644
--- a/src/map.c
+++ b/src/map.c
@@ -1304,11 +1304,12 @@ static struct HXrbnode *HXrbtrav_rewalk(struct HXrbtrav *trav)
trav->current = trav->path[--trav->depth];
if (trav->current == NULL)
fprintf(stderr, "btrav_rewalk: problem: current==NULL\n");
- HXrbtrav_checkpoint(trav, trav->current);
+ else
+ HXrbtrav_checkpoint(trav, trav->current);
}
trav->tid = btree->tid;
- if (go_next)
+ if (trav->current != nullptr && go_next)
return HXrbtrav_next(trav);
else
return trav->current;