textviewer: Workaround for musl libc

musl doesn't unload shared objects when we dlclose() the handle.  This means
it also never re-initializes them if we try to re-launch.

This means that global state is persisted across invocations instead of
being wiped.  Until we come up with a proper workaround we can apply
globally, have the textviewer clean up the important global state when
it exits.

Change-Id: I43bf38e6e9f0e7d824931740daff6c060537235a
This commit is contained in:
Solomon Peachy 2025-08-26 16:43:19 -04:00
parent 9e3bb65228
commit 088806550b

View file

@ -360,8 +360,10 @@ void tv_finalize_display(void)
}
/* undo viewport */
if (is_initialized_vp)
if (is_initialized_vp) {
rb->viewportmanager_theme_undo(SCREEN_MAIN, false);
is_initialized_vp = false; // Workaround for musl libc
}
}
bool tv_exist_scrollbar(void)