summaryrefslogtreecommitdiffstats
path: root/media/libstagefright/webm
diff options
context:
space:
mode:
Diffstat (limited to 'media/libstagefright/webm')
-rw-r--r--media/libstagefright/webm/WebmElement.cpp2
-rw-r--r--media/libstagefright/webm/WebmFrameThread.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/media/libstagefright/webm/WebmElement.cpp b/media/libstagefright/webm/WebmElement.cpp
index c978966..a008cab 100644
--- a/media/libstagefright/webm/WebmElement.cpp
+++ b/media/libstagefright/webm/WebmElement.cpp
@@ -119,7 +119,7 @@ int WebmElement::write(int fd, uint64_t& size) {
off64_t mapSize = curOff - alignedOff;
off64_t pageOff = off - alignedOff;
void *dst = ::mmap64(NULL, mapSize, PROT_WRITE, MAP_SHARED, fd, alignedOff);
- if ((int) dst == -1) {
+ if (dst == MAP_FAILED) {
ALOGE("mmap64 failed; errno = %d", errno);
ALOGE("fd %d; flags: %o", fd, ::fcntl(fd, F_GETFL, 0));
return errno;
diff --git a/media/libstagefright/webm/WebmFrameThread.cpp b/media/libstagefright/webm/WebmFrameThread.cpp
index 5addd3c..a4b8a42 100644
--- a/media/libstagefright/webm/WebmFrameThread.cpp
+++ b/media/libstagefright/webm/WebmFrameThread.cpp
@@ -48,7 +48,7 @@ status_t WebmFrameThread::start() {
status_t WebmFrameThread::stop() {
void *status;
pthread_join(mThread, &status);
- return (status_t) status;
+ return (status_t)(intptr_t)status;
}
//=================================================================================================