summaryrefslogtreecommitdiff
path: root/platform/android/src/android_gl_thread.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'platform/android/src/android_gl_thread.hpp')
-rw-r--r--platform/android/src/android_gl_thread.hpp18
1 files changed, 8 insertions, 10 deletions
diff --git a/platform/android/src/android_gl_thread.hpp b/platform/android/src/android_gl_thread.hpp
index 1c2412d594..78777aa475 100644
--- a/platform/android/src/android_gl_thread.hpp
+++ b/platform/android/src/android_gl_thread.hpp
@@ -44,20 +44,18 @@ public:
// Only safe on the GL Thread
void process() {
- while (true) {
- std::unique_lock<std::mutex> lock(mutex);
+ std::unique_lock<std::mutex> lock(mutex);
- if (queue.empty()) {
- return;
- }
+ if (queue.empty()) {
+ return;
+ }
- auto scheduled = queue.front();
- queue.pop();
+ auto scheduled = queue.front();
+ queue.pop();
- lock.unlock();
+ lock.unlock();
- Mailbox::maybeReceive(scheduled);
- }
+ Mailbox::maybeReceive(scheduled);
}
// Only safe to access on the GL Thread