[HWUI] Hook up ANativeWindow_allocateBuffers

Bug: 137012798
Test: builds
Change-Id: Iefe7b73470cb6229fc72d1a1aa33eceb827f527c
diff --git a/libs/hwui/renderthread/CanvasContext.cpp b/libs/hwui/renderthread/CanvasContext.cpp
index 096e253..699b96a 100644
--- a/libs/hwui/renderthread/CanvasContext.cpp
+++ b/libs/hwui/renderthread/CanvasContext.cpp
@@ -205,7 +205,8 @@
 
 void CanvasContext::allocateBuffers() {
     if (mNativeSurface) {
-        mNativeSurface->allocateBuffers();
+        ANativeWindow* anw = mNativeSurface->getNativeWindow();
+        ANativeWindow_allocateBuffers(anw);
     }
 }