summaryrefslogtreecommitdiffstats
path: root/native
diff options
context:
space:
mode:
authorJeff Brown <jeffbrown@google.com>2010-10-05 15:35:37 -0700
committerJeff Brown <jeffbrown@google.com>2010-10-07 13:26:39 -0700
commit415d8c38199e258dfce92cdb0c69e056b3b51ef8 (patch)
tree5bf6d167a19b272f2a153df6010a7dd6f58a274f /native
parent930d6c3cd5ad387489eb1d35a38beeafe54166b6 (diff)
downloadframeworks_base-415d8c38199e258dfce92cdb0c69e056b3b51ef8.zip
frameworks_base-415d8c38199e258dfce92cdb0c69e056b3b51ef8.tar.gz
frameworks_base-415d8c38199e258dfce92cdb0c69e056b3b51ef8.tar.bz2
Switch Looper back to using poll() instead of epoll().
Added a couple of micro-optimizations to avoid calling wake() unnecessarily and reduce JNI overhead slightly. Fixed a minor issue where we were not clearing the "next" field of Messages returned by the MessageQueue so the Message would hold on to its successor and potentially prevent the GC from collecting it if the message were leaked somehow. Change-Id: I488d29417ce0cdd7d0e447cda76ec978ef7f811c
Diffstat (limited to 'native')
-rw-r--r--native/include/android/looper.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/native/include/android/looper.h b/native/include/android/looper.h
index a63b744..a9d8426 100644
--- a/native/include/android/looper.h
+++ b/native/include/android/looper.h
@@ -135,6 +135,15 @@ enum {
* to specify this event flag in the requested event set.
*/
ALOOPER_EVENT_HANGUP = 1 << 3,
+
+ /**
+ * The file descriptor is invalid.
+ * For example, the file descriptor was closed prematurely.
+ *
+ * The looper always sends notifications about invalid file descriptors; it is not necessary
+ * to specify this event flag in the requested event set.
+ */
+ ALOOPER_EVENT_INVALID = 1 << 4,
};
/**