summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Peiyong Lin <lpy@google.com> 2021-06-03 18:11:56 +0000
committer Peiyong Lin <lpy@google.com> 2021-06-03 18:11:56 +0000
commit90a90f12ed2051261b31363d79bfb11a6db1cd1a (patch)
treec7bb2152648cdc5c201672262216a863097f5746
parentf3e492125bf0df905e98a138d972c917d8f028db (diff)
Make sure ANATIVEWINDOW_QUERY_BUFFER_AGE is identified as VNDK API.
Previously when we switch to only expose VNDK header, the ANativeWindow_query doesn't properly recognize ANATIVEWINDOW_QUERY_BUFFER_AGE as a VNDK query and hence a -EINVAL was returned. This patch makes sure it is identified and skipped to complete the actual query. Bug: b/189551931 Test: manual Change-Id: I9d4ef74dec3315e661e5a01e7b34a9f97f41fe78
-rw-r--r--libs/nativewindow/ANativeWindow.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/libs/nativewindow/ANativeWindow.cpp b/libs/nativewindow/ANativeWindow.cpp
index ada689ac42..75f2385174 100644
--- a/libs/nativewindow/ANativeWindow.cpp
+++ b/libs/nativewindow/ANativeWindow.cpp
@@ -213,6 +213,7 @@ int ANativeWindow_query(const ANativeWindow* window, ANativeWindowQuery what, in
case ANATIVEWINDOW_QUERY_DEFAULT_WIDTH:
case ANATIVEWINDOW_QUERY_DEFAULT_HEIGHT:
case ANATIVEWINDOW_QUERY_TRANSFORM_HINT:
+ case ANATIVEWINDOW_QUERY_BUFFER_AGE:
// these are part of the VNDK API
break;
case ANATIVEWINDOW_QUERY_MIN_SWAP_INTERVAL: