Merge "NdkMedia: fix android.mediav2.cts.CodecEncoderSurfaceTest failed." into main
diff --git a/media/ndk/NdkMediaCodec.cpp b/media/ndk/NdkMediaCodec.cpp
index ed31c02..e422809 100644
--- a/media/ndk/NdkMediaCodec.cpp
+++ b/media/ndk/NdkMediaCodec.cpp
@@ -668,7 +668,7 @@
         if (out_size != NULL) {
             *out_size = abuf->capacity();
         }
-        return abuf->data();
+        return abuf->base();
     }
 
     android::Vector<android::sp<android::MediaCodecBuffer> > abufs;
@@ -685,7 +685,7 @@
         if (out_size != NULL) {
             *out_size = abufs[idx]->capacity();
         }
-        return abufs[idx]->data();
+        return abufs[idx]->base();
     }
     ALOGE("couldn't get input buffers");
     return NULL;
@@ -703,7 +703,7 @@
         if (out_size != NULL) {
             *out_size = abuf->capacity();
         }
-        return abuf->data();
+        return abuf->base();
     }
 
     android::Vector<android::sp<android::MediaCodecBuffer> > abufs;
@@ -716,7 +716,7 @@
         if (out_size != NULL) {
             *out_size = abufs[idx]->capacity();
         }
-        return abufs[idx]->data();
+        return abufs[idx]->base();
     }
     ALOGE("couldn't get output buffers");
     return NULL;