MMS_MESSAGE_DATA_S *pMmsMsgData = &mmsMsgData;
- if (pMmsMsgData == NULL)
- return;
-
/* Get the text data from the 1st slide. */
if (pMmsMsgData->pageCnt > 0) {
pPage = _MsgMmsGetPage(pMmsMsgData, 0);
pVBody->pTop = NULL;
pVBody->pCur = NULL;
pVBody->pNext = NULL;
- pCurrent->pNext = pVBody;
+ if (pCurrent)
+ pCurrent->pNext = pVBody;
pCurrent = pVBody;
}
}
memset(pTemp, 0, sizeof(VObject));
pTemp->property = type;
- if (pCurrent->pTop == NULL) {
- pCurrent->pTop = pTemp;
- pCurrent->pCur = pTemp;
- } else {
- pCurrent->pCur->pSibling = pTemp;
- pCurrent->pCur = pTemp;
+ if (pCurrent) {
+ if (pCurrent->pTop == NULL) {
+ pCurrent->pTop = pTemp;
+ pCurrent->pCur = pTemp;
+ } else {
+ pCurrent->pCur->pSibling = pTemp;
+ pCurrent->pCur = pTemp;
+ }
}
break;