LibCore: Don't check for Core::NotificationType::None on Android

In this section on Android it seems to loop itself for some reason
As a quick hack we can just not check for Core::NotificationType::None
This commit is contained in:
Olekoop 2024-07-07 11:03:48 +02:00 committed by Andrew Kaster
commit cb6e438019
Notes: sideshowbarker 2024-07-17 03:03:44 +09:00

View file

@ -421,6 +421,11 @@ try_select_again:
if (error_or_marked_fd_count.value() != 0) {
// Handle file system notifiers by making them normal events.
for (size_t i = 1; i < thread_data.poll_fds.size(); ++i) {
// FIXME: Make the check work under Android, pehaps use ALooper
#ifdef AK_OS_ANDROID
auto& notifier = *thread_data.notifier_by_index[i];
ThreadEventQueue::current().post_event(notifier, make<NotifierActivationEvent>(notifier.fd(), notifier.type()));
#else
auto& revents = thread_data.poll_fds[i].revents;
auto& notifier = *thread_data.notifier_by_index[i];
@ -436,6 +441,7 @@ try_select_again:
type &= notifier.type();
if (type != NotificationType::None)
ThreadEventQueue::current().post_event(notifier, make<NotifierActivationEvent>(notifier.fd(), type));
#endif
}
}