Fix for issue 4133431 "Remove OSAL layer" in JNI

Change-Id: I55f43989a8b89a3811468b30646fe1af0c87b386
diff --git a/media/jni/mediaeditor/VideoBrowserMain.c b/media/jni/mediaeditor/VideoBrowserMain.c
index caf4497..cddab60 100755
--- a/media/jni/mediaeditor/VideoBrowserMain.c
+++ b/media/jni/mediaeditor/VideoBrowserMain.c
@@ -159,15 +159,15 @@
             VIDEOBROWSER, (M4OSA_Char*)"Video browser context");
 
     CHECK_PTR(videoBrowserCreate, pContext,err, M4ERR_ALLOC);
-    M4OSA_memset((M4OSA_MemAddr8)pContext, sizeof(VideoBrowserContext), 0);
+    memset((void *)pContext, 0,sizeof(VideoBrowserContext));
 
     /*--- Initialize the context parameters ---*/
     pContext->m_state = VideoBrowser_kVBCreating ;
     pContext->m_frameColorType = clrType;
 
     /*--- Copy the file reader functions ---*/
-    M4OSA_memcpy((M4OSA_MemAddr8)&pContext->m_fileReadPtr,
-                 (M4OSA_MemAddr8)ptrF,
+    memcpy((void *)&pContext->m_fileReadPtr,
+                 (void *)ptrF,
                  sizeof(M4OSA_FileReadPointer)) ;
 
     /* PR#SP00013 DGR bug 13 : first frame is not visible */
diff --git a/media/jni/mediaeditor/VideoEditorMain.cpp b/media/jni/mediaeditor/VideoEditorMain.cpp
index 47b334f..b792295 100755
--- a/media/jni/mediaeditor/VideoEditorMain.cpp
+++ b/media/jni/mediaeditor/VideoEditorMain.cpp
@@ -1193,9 +1193,9 @@
         (M4OSA_Char*)"Malloc for temp 3gp file");
     if (pTemp3gpFilePath != M4OSA_NULL)
     {
-        M4OSA_memset(pTemp3gpFilePath  ,
+        memset((void *)pTemp3gpFilePath  ,0,
             strlen((const char*)pContext->initParams.pTempPath)
-            + strlen((const char*)TEMP_MCS_OUT_FILE_PATH) + 1,0);
+            + strlen((const char*)TEMP_MCS_OUT_FILE_PATH) + 1);
         strncat((char *)pTemp3gpFilePath,
             (const char *)pContext->initParams.pTempPath  ,
             (size_t) ((M4OSA_Char*)pContext->initParams.pTempPath));
@@ -1709,9 +1709,9 @@
                     goto videoEditor_populateSettings_cleanup;
                 }
 
-                M4OSA_memcpy((M4OSA_Int8 *)&pContext->pEditSettings->\
+                memcpy((void *)&pContext->pEditSettings->\
                     Effects[j].xVSS.pFramingBuffer->\
-                    pac_data[0],(M4OSA_Int8 *)&aFramingCtx->FramingRgb->pac_data[0],(width*height*2));
+                    pac_data[0],(void *)&aFramingCtx->FramingRgb->pac_data[0],(width*height*2));
 
                 //As of now rgb type is 565
                 pContext->pEditSettings->Effects[j].xVSS.rgbType =
@@ -1854,8 +1854,8 @@
                 (M4OSA_UInt32)(strlen((const char*)pTempChar))+1 /* +1 for NULL termination */, 0,
                 (M4OSA_Char*)"strPath allocation " );
             if (pContext->mAudioSettings->pFile != M4OSA_NULL) {
-                M4OSA_memcpy((M4OSA_Int8 *)pContext->mAudioSettings->pFile ,
-                    (M4OSA_Int8 *)pTempChar , strlen((const char*)pTempChar));
+                memcpy((void *)pContext->mAudioSettings->pFile ,
+                    (void *)pTempChar , strlen((const char*)pTempChar));
                 ((M4OSA_Int8 *)(pContext->mAudioSettings->pFile))[strlen((const char*)pTempChar)] = '\0';
                 pEnv->ReleaseStringUTFChars(strPath,(const char *)pTempChar);
             } else {
@@ -1879,8 +1879,8 @@
                 (M4OSA_UInt32)(strlen((const char*)pTempChar))+1 /* +1 for NULL termination */, 0,
                 (M4OSA_Char*)"strPCMPath allocation " );
             if (pContext->mAudioSettings->pPCMFilePath != M4OSA_NULL) {
-                M4OSA_memcpy((M4OSA_Int8 *)pContext->mAudioSettings->pPCMFilePath ,
-                    (M4OSA_Int8 *)pTempChar , strlen((const char*)pTempChar));
+                memcpy((void *)pContext->mAudioSettings->pPCMFilePath ,
+                    (void *)pTempChar , strlen((const char*)pTempChar));
                 ((M4OSA_Int8 *)(pContext->mAudioSettings->pPCMFilePath))[strlen((const char*)pTempChar)] = '\0';
                 pEnv->ReleaseStringUTFChars(strPCMPath,(const char *)pTempChar);
             } else {
@@ -3287,7 +3287,7 @@
     /* loop until EOF */
     do
     {
-        M4OSA_memset((M4OSA_MemAddr8)bufferIn.m_dataAddress,bufferIn.m_bufferSize, 0);
+        memset((void *)bufferIn.m_dataAddress,0,bufferIn.m_bufferSize);
 
         numBytesToRead = samplesCountInBytes;
 
diff --git a/media/jni/mediaeditor/VideoEditorOsal.cpp b/media/jni/mediaeditor/VideoEditorOsal.cpp
index 035f59a..339c0d1 100755
--- a/media/jni/mediaeditor/VideoEditorOsal.cpp
+++ b/media/jni/mediaeditor/VideoEditorOsal.cpp
@@ -280,7 +280,7 @@
         if (M4OSA_NULL != pData)
         {
             // Reset the allocated memory.
-            M4OSA_memset((M4OSA_MemAddr8)pData, size, 0);
+            memset((void *)pData, 0,size);
 #ifdef OSAL_MEM_LEAK_DEBUG
             // Update the allocated block count.
             gAllocatedBlockCount++;
diff --git a/media/jni/mediaeditor/VideoEditorThumbnailMain.cpp b/media/jni/mediaeditor/VideoEditorThumbnailMain.cpp
index b1f9fe4..461bdd0 100755
--- a/media/jni/mediaeditor/VideoEditorThumbnailMain.cpp
+++ b/media/jni/mediaeditor/VideoEditorThumbnailMain.cpp
@@ -134,7 +134,7 @@
 
         for (j = 0; j < pPlane->u_height; j++)
         {
-            M4OSA_memcpy((M4OSA_MemAddr8 )dst, (M4OSA_MemAddr8 )src, pPlane->u_stride);
+            memcpy((void * )dst, (void * )src, pPlane->u_stride);
             for (i = pPlane->u_width; i < pC->m_width; i++)
             {
                 dst[i] = 0;
@@ -170,7 +170,7 @@
     M4OSA_TRACE3_1("context value is = %d",pContext);
     CHECK_PTR(ThumbnailOpen, pContext, err, M4ERR_ALLOC);
 
-    M4OSA_memset((M4OSA_MemAddr8)pContext, sizeof(ThumbnailContext), 0);
+    memset((void *)pContext, 0,sizeof(ThumbnailContext));
 
     M4OSA_FileReadPointer optFP;
     M4OSA_FileReadPointer llFP;