err = MsgAddNotification(noti_type, msg_info);
break;
default:
- MSG_DEBUG("No matching type [%d]");
+ MSG_DEBUG("No matching type ");
break;
}
addrLen = strlen(pSetting->option.smscList.smscData[index].smscAddr.address);
if (addrLen > SMSC_ADDR_MAX) {
- MSG_DEBUG("SMSC address is too long [%d]", strlen(pSetting->option.smscList.smscData[index].smscAddr.address));
+ MSG_DEBUG("SMSC address is too long [%lu]", strlen(pSetting->option.smscList.smscData[index].smscAddr.address));
return MSG_ERR_SET_SIM_SET;
} else if (addrLen < 2) {
MSG_DEBUG("SMSC address is too short [%d]", addrLen);
break;
case VMSG_TYPE_SUBJECT : {
- MSG_DEBUG("subject length is [%d].", strlen(pObject->pszValue[0]));
+ MSG_DEBUG("subject length is [%lu].", strlen(pObject->pszValue[0]));
if(strlen(pObject->pszValue[0]) > 0) {
strncpy(msgInfo.subject, pObject->pszValue[0], MAX_SUBJECT_LEN);
return MSG_ERR_STORAGE_ERROR;
}
- MSG_SEC_DEBUG("Save Message Data into file : size[%d] name[%s]\n", pMsg->dataSize, fileName);
+ MSG_SEC_DEBUG("Save Message Data into file : size[%lu] name[%s]\n", pMsg->dataSize, fileName);
if (MsgWriteIpcFile(fileName, msgData, pMsg->dataSize) == false) {
dbHandle->finalizeQuery();
}
return MSG_ERR_STORAGE_ERROR;
}
- MSG_SEC_DEBUG("Save Message Data into file : size[%d] name[%s]\n", pMsg->dataSize, tempFileName);
+ MSG_SEC_DEBUG("Save Message Data into file : size[%lu] name[%s]\n", pMsg->dataSize, tempFileName);
if (MsgWriteIpcFile(tempFileName, pDestMsg, pMsg->dataSize) == false) {
if(pDestMsg) {
report_status[i].status = dbHandle->getColumnToInt(index++);
report_status[i].statusTime = (time_t)dbHandle->getColumnToInt(index++);
- MSG_SEC_DEBUG("(%d/%d) address = %s, report_type = %d, report_status = %d, report_time = %d", i+1, rowCnt, report_status[i].addressVal, report_status[i].type, report_status[i].status, report_status[i].statusTime);
+ MSG_SEC_DEBUG("(%d/%d) address = %s, report_type = %d, report_status = %d, report_time = %ld", i+1, rowCnt, report_status[i].addressVal, report_status[i].type, report_status[i].status, report_status[i].statusTime);
}
*pReportStatus = report_status;
report_status[i].status = dbHandle->getColumnToInt(index++);
report_status[i].statusTime = (time_t)dbHandle->getColumnToInt(index++);
- MSG_DEBUG("(%d/%d) addr = %s, report_type = %d, report_status = %d, report_time = %d", i+1, rowCnt, report_status[i].addressVal, report_status[i].type, report_status[i].status, report_status[i].statusTime);
+ MSG_DEBUG("(%d/%d) addr = %s, report_type = %d, report_status = %d, report_time = %ld", i+1, rowCnt, report_status[i].addressVal, report_status[i].type, report_status[i].status, report_status[i].statusTime);
}
*pReportStatus = report_status;
dbHandle->getColumnToString(index++, MSG_FILEPATH_LEN_MAX, filePath);
if(strlen(filePath) > 1) {
- MSG_DEBUG("strlen(filePath) [%d]", strlen(filePath));
+ MSG_DEBUG("strlen(filePath) [%lu]", strlen(filePath));
MSG_SEC_DEBUG("filePath [%s]", filePath);
if(MsgGetFileSize(filePath) < 0) {
MSG_DEBUG("check pushMsg data");
MSG_DEBUG("pushMsg.action : [%d]", pushMsg.action);
- MSG_DEBUG("pushMsg.received : [%d]", pushMsg.received);
- MSG_DEBUG("pushMsg.created : [%d]", pushMsg.created);
- MSG_DEBUG("pushMsg.expires : [%d]", pushMsg.expires);
+ MSG_DEBUG("pushMsg.received : [%lu]", pushMsg.received);
+ MSG_DEBUG("pushMsg.created : [%lu]", pushMsg.created);
+ MSG_DEBUG("pushMsg.expires : [%lu]", pushMsg.expires);
MSG_SEC_DEBUG("pushMsg.id : [%s]", pushMsg.id);
MSG_DEBUG("pushMsg.href : [%s]", pushMsg.href);
MSG_DEBUG("pushMsg.contents : [%s]", pushMsg.contents);
return MsgMakeEvent(NULL, 0, MSG_EVENT_PLG_SENT_STATUS_CNF, MSG_SUCCESS, (void**)ppEvent);
}
- MSG_DEBUG("REQID %d, listenerFD %d, handleAddr %x, msgId %d", pStatus->reqId, prxInfo->listenerFd, prxInfo->handleAddr, prxInfo->sentMsgId);
+ MSG_DEBUG("REQID %d, listenerFD %d, handleAddr %lu, msgId %d", pStatus->reqId, prxInfo->listenerFd, prxInfo->handleAddr, prxInfo->sentMsgId);
/* if APP send and quit(not exist at this time), don't send the data up. */
if (prxInfo->handleAddr == 0) {
javamms_list& listenerList = MsgTransactionManager::instance()->getJavaMMSList();
javamms_list::iterator it = listenerList.begin();
- MSG_DEBUG("listenerList size:%d ", listenerList.size());
+ MSG_DEBUG("listenerList size:%lu ", listenerList.size());
if (msgInfo.networkStatus == MSG_NETWORK_SEND_FAIL && msgInfo.msgType.subType == MSG_SENDREQ_MMS) {
for ( ; it != listenerList.end() ; it++) {
if (pPrxInfo == NULL)
THROW(MsgException::SENT_STATUS_ERROR, "Input Parameter is NULL");
- MSG_DEBUG("msg for submit: reqId %d listenerFd %d handleAddr %x", reqId, pPrxInfo->listenerFd, pPrxInfo->handleAddr);
+ MSG_DEBUG("msg for submit: reqId %d listenerFd %d handleAddr %lu", reqId, pPrxInfo->listenerFd, pPrxInfo->handleAddr);
MsgMutexLocker lock(mx);
break;
}
- MSG_MGR_DEBUG("nRepeatTime = %d", nRepeatTime);
+ MSG_MGR_DEBUG("nRepeatTime = %ld", nRepeatTime);
if (nRepeatTime > 0) {
if (g_alarmId > 0) {
static int msg_send_single_sms(const char *phone_num, const char *sms_text, msg_simple_sent_status_cb cb, void *user_param)
{
if (phone_num == NULL || sms_text == NULL || cb == NULL) {
- MSG_SEC_DEBUG("Invalid parameter [%s] [%s] [%s]", phone_num, sms_text, cb);
+ MSG_SEC_DEBUG("Invalid parameter [%s] [%s] [%p]", phone_num, sms_text, cb);
return MSG_ERR_INVALID_PARAMETER;
}
CHECK_MSG_SUPPORTED(MSG_TELEPHONY_SMS_FEATURE);
if (phone_num_list == NULL || sms_text == NULL || cb == NULL) {
- MSG_SEC_DEBUG("Invalid parameter [%s] [%s] [%s]", phone_num_list, sms_text, cb);
+ MSG_SEC_DEBUG("Invalid parameter [%s] [%s] [%p]", phone_num_list, sms_text, cb);
return MSG_ERR_INVALID_PARAMETER;
}
MSG_MESSAGE_HIDDEN_S *reqmsg = (MSG_MESSAGE_HIDDEN_S*)msg_s->data;
if (reqmsg->dataSize <= 0) {
- MSG_FATAL("msg size is invalid : [%d]", reqmsg->dataSize);
+ MSG_FATAL("msg size is invalid : [%lu]", reqmsg->dataSize);
return MSG_ERR_INVALID_PARAMETER;
}
if (((unsigned long)(d - ret)) != *len) {
*len = d - ret;
- MSG_DEBUG("base64 encoding length = %d \n", *len);
+ MSG_DEBUG("base64 encoding length = %lu \n", *len);
}
return true;
if (char_set) {
strncpy(char_set, (char*)((start_ptr + 2)), q1_ptr - (start_ptr + 2));
- MSG_DEBUG("character set [%s][%d]", char_set, strlen(char_set));
+ MSG_DEBUG("character set [%s][%lu]", char_set, strlen(char_set));
} else {
MSG_DEBUG("fail to calloc");
goto __CATCH;
goto __CATCH;
strncpy(l_encoded_text, (char*)(q2_ptr + 1), end_ptr - q2_ptr -1);
- MSG_DEBUG("encoded text [%s][%d]", l_encoded_text, strlen(l_encoded_text));
+ MSG_DEBUG("encoded text [%s][%lu]", l_encoded_text, strlen(l_encoded_text));
} else {
MSG_DEBUG("encoded text is NULL");
goto __CATCH;
}
if (strcasecmp(encoding, "B") == 0) {
- MSG_DEBUG("Base64 encoded text [%s][%d]", encoded_text, strlen(encoded_text));
+ MSG_DEBUG("Base64 encoded text [%s][%lu]", encoded_text, strlen(encoded_text));
decoded_text = (char *)MsgDecodeBase64((unsigned char *)encoded_text, strlen(encoded_text), (ULONG *)&decoded_len);
char *result_text = NULL;
int result_text_len = 0;
- MSG_DEBUG("Base64 decoded text [%s][%d], outlen [%d]", decoded_text, strlen(decoded_text), decoded_len);
+ MSG_DEBUG("Base64 decoded text [%s][%lu], outlen [%d]", decoded_text, strlen(decoded_text), decoded_len);
if (MmsPluginTextConvert("UTF-8", charset, decoded_text, decoded_len, &result_text, &result_text_len) == false) {
MSG_DEBUG("MmsPluginTextConvert Fail");
}
if (result_text) {
- MSG_DEBUG("Text convert result [%s][%d]", result_text, strlen(result_text));
+ MSG_DEBUG("Text convert result [%s][%lu]", result_text, strlen(result_text));
result_string.append(result_text, result_text_len);
char *result_text = NULL;
int result_text_len = 0;
- MSG_DEBUG("Qprint encoded text [%s][%d]", encoded_text, strlen(encoded_text));
+ MSG_DEBUG("Qprint encoded text [%s][%lu]", encoded_text, strlen(encoded_text));
decoded_text = (char *)MsgDecodeQuotePrintable((unsigned char *)encoded_text, strlen(encoded_text), (ULONG *)&decoded_len);
if (decoded_text && decoded_len > 0) {
- MSG_DEBUG("Qprint decoded text [%s][%d], outlen [%d]", decoded_text, strlen(decoded_text), decoded_len);
+ MSG_DEBUG("Qprint decoded text [%s][%zu], outlen [%u]", decoded_text, strlen(decoded_text), decoded_len);
if (MmsPluginTextConvert("UTF-8", charset, decoded_text, decoded_len, &result_text, &result_text_len) == false) {
MSG_DEBUG("MmsPluginTextConvert Fail");
}
if (result_text) {
- MSG_DEBUG("Text convert result [%s][%d]", result_text, strlen(result_text));
+ MSG_DEBUG("Text convert result [%s][%lu]", result_text, strlen(result_text));
result_string.append(result_text, result_text_len);
MSG_SEC_INFO("Profile Apn = [%s]", apn);
ret = connection_profile_get_cellular_auth_info(profile, &auth_type, &user_name, &password);
- MSG_SEC_INFO("Profile Auth Type = [%d]", &auth_type);
- MSG_SEC_INFO("Profile Auth Name = [%s]", &user_name);
- MSG_SEC_INFO("Profile Auth Passward = [%s]", &password);
+ MSG_SEC_INFO("Profile Auth Type = [%p]", &auth_type);
+ MSG_SEC_INFO("Profile Auth Name = [%s]", user_name);
+ MSG_SEC_INFO("Profile Auth Passward = [%s]", password);
ret = connection_profile_get_cellular_home_url(profile, &home_url);
MSG_SEC_INFO("Profile Home Url = [%s]", home_url);
goto __CATCH;
}
- MSG_SEC_INFO("Date = [%u][%d]", mmsHeader.date, (const time_t *)&mmsHeader.date);
+ MSG_SEC_INFO("Date = [%lu][%p]", mmsHeader.date, (const time_t *)&mmsHeader.date);
break;
case MMS_CODE_DELIVERYREPORT:
goto __CATCH;
}
- MSG_SEC_INFO("X-Mms-Message-Size = [%d]", mmsHeader.msgSize);
+ MSG_SEC_INFO("X-Mms-Message-Size = [%lu]", mmsHeader.msgSize);
break;
case MMS_CODE_MSGSTATUS:
goto __CATCH;
}
mmsHeader.reportAllowed = (MmsReportAllowed)MmsGetBinaryType(MmsCodeReportAllowed, (UINT16)(oneByte & 0x7F));
- MSG_SEC_INFO("X-Mms-Report-Allowed = [%d]", MmsDebugGetMmsReportAllowed(mmsHeader.reportAllowed));
+ MSG_SEC_INFO("X-Mms-Report-Allowed = [%s]", MmsDebugGetMmsReportAllowed(mmsHeader.reportAllowed));
break;
case MMS_CODE_SENDERVISIBILLITY:
/* Text-value */
if (__MmsBinaryDecodeInteger(pFile, &integer, &intLen, totalLength) == true) {
- MSG_DEBUG("Unsupported parameter(%d)\n", integer);
+ MSG_DEBUG("Unsupported parameter(%lu)\n", integer);
if (__MmsBinaryDecodeCheckAndDecreaseLength(&valueLength, intLen) == false)
goto __RETURN;
} else {
goto __CATCH;
}
- MSG_INFO("Number of Entries = [%d]", *npEntries);
+ MSG_INFO("Number of Entries = [%lu]", *npEntries);
return true;
}
if (__MmsBinaryDecodeEachPart(pFile, szFilePath, &(pMultipart->type), pMultipart->pBody, totalLength) == false) {
- MSG_DEBUG("MmsBinaryDecodeEachPart is fail.(nEntries = %d)\n", nEntries);
+ MSG_DEBUG("MmsBinaryDecodeEachPart is fail.(nEntries = %lu)\n", nEntries);
goto __CATCH;
}
}
*nCharSet = MmsGetBinaryType(MmsCodeCharSet, (UINT16)integer);
- MSG_DEBUG("Decoded charset MIBenum = [%d], charset enum = [%d]", integer, *nCharSet);
+ MSG_DEBUG("Decoded charset MIBenum = [%lu], charset enum = [%lu]", integer, *nCharSet);
if (*nCharSet == MIME_UNKNOWN) {
MSG_DEBUG("MmsGetBinaryType fail..");
*nCharSet = MSG_CHARSET_UNKNOWN;
memcpy(&pMsg->mmsAttrib.expiryTime, &mmsHeader.expiryTime, sizeof(MmsTimeStruct));
- MSG_DEBUG("@@@@@pMsg->mmsAttrib.deliveryTime=[%d]", pMsg->mmsAttrib.deliveryTime);
+ MSG_DEBUG("@@@@@pMsg->mmsAttrib.deliveryTime=[%u]", pMsg->mmsAttrib.deliveryTime.time);
pMsg->mmsAttrib.msgClass = mmsHeader.msgClass;
}
gMmsEncodeCurOffset = MsgFtell(pFile);
if (gMmsEncodeCurOffset < 0) {
- MSG_DEBUG("MsgFtell returns negative value [%ld]", gMmsEncodeCurOffset);
+ MSG_DEBUG("MsgFtell returns negative value [%d]", gMmsEncodeCurOffset);
goto __CATCH;
}
}
gMmsEncodeCurOffset = MsgFtell(pFile);
if (gMmsEncodeCurOffset < 0) {
- MSG_DEBUG("MsgFtell returns negative value [%ld]", gMmsEncodeCurOffset);
+ MSG_DEBUG("MsgFtell returns negative value [%d]", gMmsEncodeCurOffset);
goto __CATCH;
}
gMmsEncodeCurOffset = MsgFtell(pFile);
if (gMmsEncodeCurOffset < 0) {
- MSG_DEBUG("MsgFtell returns negative value [%ld]", gMmsEncodeCurOffset);
+ MSG_DEBUG("MsgFtell returns negative value [%d]", gMmsEncodeCurOffset);
goto __CATCH;
}
}
}
} else {
- MSG_DEBUG("date has a negative value (%d)", dateSec);
+ MSG_DEBUG("date has a negative value (%ld)", dateSec);
goto __CATCH;
}
return true;
PRINT_KEY_VAL_STR("mms type", "Unknown");
}
- PRINT_KEY_VAL_STR("mms ver", pMmsMsg->mmsAttrib.version);
+ PRINT_KEY_VAL_INT("mms ver", pMmsMsg->mmsAttrib.version);
}
int MmsUpdateMultipartList(MSG_MESSAGE_INFO_S *pMsgInfo)
}
if (pDest == NULL || bytes_written == 0 || bytes_read == 0) {
- MSG_DEBUG("Error in g_convert, pDest = %s, bytes_written = %d, bytes_read = %d\n", pDest, bytes_written, bytes_read);
+ MSG_DEBUG("Error in g_convert, pDest = %s, bytes_written = %lu, bytes_read = %lu\n", pDest, bytes_written, bytes_read);
goto __CATCH;
}
==================================================================================================*/
void TapiEventDeviceReady(TapiHandle *handle, const char *noti_id, void *data, void *user_data)
{
- MSG_DEBUG("TapiEventDeviceReady is called. : noti_id = [%d]", noti_id);
+ MSG_DEBUG("TapiEventDeviceReady is called. : noti_id = [%s]", noti_id);
try {
/* Call Event Handler */
MSG_DEBUG("msgInfo.msgType.mainType : %d", msgInfo.msgType.mainType);
MSG_DEBUG("msgInfo.msgType.subType : %d", msgInfo.msgType.subType);
MSG_DEBUG("msgInfo.msgType.classType : %d", msgInfo.msgType.classType);
- MSG_DEBUG("msgInfo.displayTime : %d", msgInfo.displayTime);
- MSG_DEBUG("msgInfo.dataSize : %d", msgInfo.dataSize);
+ MSG_DEBUG("msgInfo.displayTime : %ld", msgInfo.displayTime);
+ MSG_DEBUG("msgInfo.dataSize : %lu", msgInfo.dataSize);
if (msgInfo.bTextSms == true)
MSG_SEC_DEBUG("msgInfo.msgText : %s", msgInfo.msgText);
else
pMsgInfo->msgPort.srcPort = 0;
pMsgInfo->displayTime = pCbMsg->recvTime;
- MSG_DEBUG("recvTime is %d", pMsgInfo->displayTime);
+ MSG_DEBUG("recvTime is %ld", pMsgInfo->displayTime);
int bufSize = pCbMsg->msgLength*2;
if (MsgCreateFileName(fileName) == false)
THROW(MsgException::FILE_ERROR, "MsgCreateFileName error");
- MSG_SEC_DEBUG("Save Message Data into file : size[%d] name[%s]\n", pMsgInfo->dataSize, fileName);
+ MSG_SEC_DEBUG("Save Message Data into file : size[%lu] name[%s]\n", pMsgInfo->dataSize, fileName);
if (MsgWriteIpcFile(fileName, tmpBuf, pMsgInfo->dataSize) == false)
THROW(MsgException::FILE_ERROR, "MsgWriteIpcFile error");
pMsgInfo->msgPort.srcPort = 0;
pMsgInfo->displayTime = EtwsMsg->pageHeader.recvTime;
- MSG_DEBUG("recvTime is %d", pMsgInfo->displayTime);
+ MSG_DEBUG("recvTime is %ld", pMsgInfo->displayTime);
MSG_DEBUG("LENGTH %d", EtwsMsg->pageLength);
pMsgInfo->bTextSms = true;
pMsgInfo->dataSize = EtwsMsg->pageLength;
pMsgInfo->dataSize = textCvt->convertUCS2ToUTF8((unsigned char*)tmpBuf, bufSize, (unsigned char*)pUserData, DataSize);
}
- MSG_DEBUG("Data Size [%d]", pMsgInfo->dataSize);
+ MSG_DEBUG("Data Size [%lu]", pMsgInfo->dataSize);
MSG_DEBUG("Data [%s]", tmpBuf);
#ifdef MSG_FW_FOR_DEBUG
if (MsgCreateFileName(fileName) == false)
THROW(MsgException::FILE_ERROR, "######## MsgCreateFileName Fail !!! #######");
- MSG_SEC_DEBUG("Save Message Data into file : size[%d] name[%s]\n", pMsgInfo->dataSize, fileName);
+ MSG_SEC_DEBUG("Save Message Data into file : size[%lu] name[%s]\n", pMsgInfo->dataSize, fileName);
if (MsgWriteIpcFile(fileName, tmpBuf, pMsgInfo->dataSize) == false)
THROW(MsgException::FILE_ERROR, "######## MsgWriteIpcFile Fail !!! #######");
pMsgInfo->dataSize = textCvt->convertUCS2ToUTF8((unsigned char*)tmpBuf, bufSize, (unsigned char*)pUserData, DataSize);
}
- MSG_DEBUG("Data Size [%d]", pMsgInfo->dataSize);
+ MSG_DEBUG("Data Size [%lu]", pMsgInfo->dataSize);
MSG_DEBUG("Data [%s]", tmpBuf);
if (pMsgInfo->dataSize > MAX_MSG_TEXT_LEN) {
if (MsgCreateFileName(fileName) == false)
THROW(MsgException::FILE_ERROR, "######## MsgCreateFileName Fail !!! #######");
- MSG_SEC_DEBUG("Save Message Data into file : size[%d] name[%s]\n", pMsgInfo->dataSize, fileName);
+ MSG_SEC_DEBUG("Save Message Data into file : size[%lu] name[%s]\n", pMsgInfo->dataSize, fileName);
if (MsgWriteIpcFile(fileName, tmpBuf, pMsgInfo->dataSize) == false)
THROW(MsgException::FILE_ERROR, "######## MsgWriteIpcFile Fail !!! #######");
MSG_DEBUG("msgInfo.msgType.mainType : %d", msgInfo.msgType.mainType);
MSG_DEBUG("msgInfo.msgType.subType : %d", msgInfo.msgType.subType);
MSG_DEBUG("msgInfo.msgType.classType : %d", msgInfo.msgType.classType);
- MSG_DEBUG("msgInfo.displayTime : %d", msgInfo.displayTime);
+ MSG_DEBUG("msgInfo.displayTime : %ld", msgInfo.displayTime);
MSG_DEBUG("msgInfo.msgPort.valid : %d", msgInfo.msgPort.valid);
MSG_DEBUG("msgInfo.encodeType : %d", msgInfo.encodeType);
- MSG_DEBUG("msgInfo.dataSize : %d", msgInfo.dataSize);
+ MSG_DEBUG("msgInfo.dataSize : %lu", msgInfo.dataSize);
MSG_DEBUG("msgInfo.sim_idx : %d", msgInfo.sim_idx);
if (msgInfo.bTextSms == true) {
MSG_DEBUG("tzname[0] [%s]", tzname[0]);
MSG_DEBUG("tzname[1] [%s]", tzname[1]);
- MSG_DEBUG("timezone [%d]", timezone);
+ MSG_DEBUG("timezone [%lu]", timezone);
MSG_DEBUG("daylight [%d]", daylight);
memset(displayTime, 0x00, sizeof(displayTime));
MSG_DEBUG("tzname[0] [%s]", tzname[0]);
MSG_DEBUG("tzname[1] [%s]", tzname[1]);
- MSG_DEBUG("timezone [%d]", timezone);
+ MSG_DEBUG("timezone [%ld]", timezone);
MSG_DEBUG("daylight [%d]", daylight);
memset(displayTime, 0x00, sizeof(displayTime));
smsc.npi = pSmsData->address.npi;
snprintf(smsc.address, sizeof(smsc.address), "%s", pSmsData->address.diallingNumber);
- MSG_SEC_DEBUG("SCA TON[%d], NPI[%d], LEN[%d], ADDR[%s]", smsc.ton, smsc.npi, strlen(smsc.address), smsc.address);
+ MSG_SEC_DEBUG("SCA TON[%d], NPI[%d], LEN[%lu], ADDR[%s]", smsc.ton, smsc.npi, strlen(smsc.address), smsc.address);
} else {
/* Set SMSC Options */
SmsPluginTransport::instance()->setSmscOptions(simIndex, &smsc);
pushHeaderLen = wspRetriveUintvarDecode(pPDUTypeData, &iPDU);
- MSG_DEBUG("PDUTypeDataLen [%d]", PDUTypeDataLen);
- MSG_DEBUG("pushHeaderLen [%d]", pushHeaderLen);
- MSG_DEBUG("iPDU [%d]", iPDU);
+ MSG_DEBUG("PDUTypeDataLen [%lu]", PDUTypeDataLen);
+ MSG_DEBUG("pushHeaderLen [%lu]", pushHeaderLen);
+ MSG_DEBUG("iPDU [%lu]", iPDU);
wspHeaderLen = pushHeaderLen + iPDU;
- MSG_DEBUG("wspBodyLen [%d]", wspBodyLen);
+ MSG_DEBUG("wspBodyLen [%lu]", wspBodyLen);
if (wspHeaderLen > 0) {
pWspHeader = new char[wspHeaderLen];
MSG_DEBUG("check pushMsg data");
MSG_DEBUG("pushMsg.action : [%d]", pushMsg.action);
- MSG_DEBUG("pushMsg.received : [%d]", pushMsg.received);
- MSG_DEBUG("pushMsg.created : [%d]", pushMsg.created);
- MSG_DEBUG("pushMsg.expires : [%d]", pushMsg.expires);
+ MSG_DEBUG("pushMsg.received : [%lu]", pushMsg.received);
+ MSG_DEBUG("pushMsg.created : [%lu]", pushMsg.created);
+ MSG_DEBUG("pushMsg.expires : [%lu]", pushMsg.expires);
MSG_SEC_DEBUG("pushMsg.id : [%s]", pushMsg.id);
MSG_DEBUG("pushMsg.href : [%s]", pushMsg.href);
MSG_DEBUG("pushMsg.contents : [%s]", pushMsg.contents);
msgInfo.sim_idx = simIndex;
getDisplayName(msgInfo.msgType.subType, msgInfo.addressList[0].addressVal);
- MSG_DEBUG("dataSize : %d", msgInfo.dataSize);
+ MSG_DEBUG("dataSize : %lu", msgInfo.dataSize);
/** Add WAP Push Msg into DB */
err = SmsPluginStorage::instance()->checkMessage(&msgInfo);
decodedValue = wspDecodeUintvar(i + 1, sourceData + *currentPointer);
*currentPointer = *currentPointer + i + 1;
- MSG_DEBUG("wspRetriveUintvarDecode: decodedValue=%d .\n", decodedValue);
+ MSG_DEBUG("wspRetriveUintvarDecode: decodedValue=%lu .\n", decodedValue);
return decodedValue;
}
/* processing normal pre-defined field decoding */
MSG_DEBUG("WspLDecodeHeader: FieldCode %X\n", fieldCode);
- MSG_DEBUG("WspLDecodeHeader: fieldSize %d\n", fieldValueLen);
+ MSG_DEBUG("WspLDecodeHeader: fieldSize %lu\n", fieldValueLen);
if ((fieldCode > wspHeaderFieldCount) && (fieldCode != 0xff)) {
MSG_DEBUG("WspLDecodeHeader: unknown fieldcode %X \n", track);
unsigned long i = 0;
/* encoded content type length body */
unsigned long tempLen;
- MSG_DEBUG("fieldValueLen: %d", fieldValueLen);
+ MSG_DEBUG("fieldValueLen: %lu", fieldValueLen);
/* Like HTTP result state 304, it's for processing without Content type. This part doesn't defined. */
if (0 == fieldValueLen) {
tempLen = AcStrlen((char*)fieldValue) + 1;
strncat((char*)temper, (char*)fieldValue, (WSP_STANDARD_STR_LEN_MAX * 5)-AcStrlen((char*)temper)-1);
- MSG_DEBUG("WspLDecodeHeader: Attention, Decoding Check of Content-Type\n ", tempLen);
+ MSG_DEBUG("WspLDecodeHeader: Attention, Decoding Check of Content-Type %lu\n ", tempLen);
}
/* If there is a parameter */
IntLen = (data[0] > 0x04) ? 0x04:data[0];
- MSG_DEBUG("WspLHeaderDecodeInteger: input %d , length %d\n", data[0], IntLen);
+ MSG_DEBUG("WspLHeaderDecodeInteger: input %d , length %lu\n", data[0], IntLen);
for (i = 0; i < IntLen; i++)
returner.seg[IntLen-(i+1)] = data[i+1];
for (i = 0 ; i < length; i++) {
returner.integer = returner.integer + (data[i] * (0x1 << ((length - (i + 1)) * 8)));
- MSG_DEBUG("WspLHeaderDecodeIntegerByLength: %d \n", returner.integer);
+ MSG_DEBUG("WspLHeaderDecodeIntegerByLength: %lu \n", returner.integer);
}
return returner.integer;
pDest->msgPort.srcPort = pSrc->srcPort;
}
- MSG_DEBUG("nSize = %d", pSrc->dataSize);
+ MSG_DEBUG("nSize = %lu", pSrc->dataSize);
MSG_DEBUG("mainType = %d", pSrc->mainType);
if (pSrc->mainType == MSG_SMS_TYPE) {
if (MsgCreateFileName(fileName) == false)
THROW(MsgException::FILE_ERROR, "MsgCreateFileName error");
- MSG_SEC_DEBUG("Save pSrc->pData into file : size[%d] name[%s]", pDest->dataSize, fileName);
+ MSG_SEC_DEBUG("Save pSrc->pData into file : size[%lu] name[%s]", pDest->dataSize, fileName);
if (MsgWriteIpcFile(fileName, (char*)pSrc->pData, pSrc->dataSize) == false)
THROW(MsgException::FILE_ERROR, "MsgWriteIpcFile error");
strncpy(pDest->msgText, (char*)pSrc->pData, pSrc->dataSize);
}
- MSG_DEBUG("pData = %s", pSrc->pData);
+ MSG_DEBUG("pData = %s",(char*) pSrc->pData);
} else {
MSG_DEBUG("pSrc->pData is NULL.");
pDest->bTextSms = true;
snprintf(pFileNameExt, strlen("JAVA")+1, "JAVA");
}
- MSG_SEC_DEBUG("Save Message Data into file : size[%d] name[%s]", pSrc->mmsDataSize, fileName);
+ MSG_SEC_DEBUG("Save Message Data into file : size[%zu] name[%s]", pSrc->mmsDataSize, fileName);
if (MsgWriteIpcFile(fileName, (char*)pSrc->pMmsData, pSrc->mmsDataSize) == false)
THROW(MsgException::FILE_ERROR, "MsgWriteIpcFile error");
pDest->pMmsData = (void*)new char[fileSize];
memset(pDest->pMmsData, 0x00, fileSize);
memcpy(pDest->pMmsData, pFileData, fileSize);
- MSG_SEC_DEBUG("Get Message Data from file : size[%d] name[%s]", pDest->mmsDataSize, pSrc->msgData);
+ MSG_SEC_DEBUG("Get Message Data from file : size[%zu] name[%s]", pDest->mmsDataSize, pSrc->msgData);
}
} else {
MSG_DEBUG("pDest->option.mmsSendOpt.priority = %d", pMms->priority);
MSG_DEBUG("pDest->option.mmsSendOpt.bReadReq = %d", pMms->bReadReq);
- MSG_DEBUG("pDest->option.mmsSendOpt.expiryTime = %d", pMms->expiryTime);
+ MSG_DEBUG("pDest->option.mmsSendOpt.expiryTime = %ld", pMms->expiryTime);
}
MSG_END();
handle_set::iterator it = openHandleSet.begin();
for (; it != openHandleSet.end(); it++) {
- MSG_DEBUG("disconnect socket for opened handle [%p]", it);
+ MSG_DEBUG("disconnect socket for opened handle [%p]", *it);
MsgHandle *handle = (MsgHandle *)*it;
handle->disconnectSocket();
}
handle_set::iterator it = openHandleSet.find(pMsgHandle);
if (it == openHandleSet.end()) {
openHandleSet.insert(pMsgHandle);
- MSG_DEBUG("New handle is added. current count = [%d]", openHandleSet.size());
+ MSG_DEBUG("New handle is added. current count = [%lu]", openHandleSet.size());
}
}
/* send the data size first */
int n = writen((const char*)&len, sizeof(len));
if (n != sizeof(len)) {
- MSG_FATAL("WARNING: write header_size[%d] not matched [%d]", n, sizeof(len));
+ MSG_FATAL("WARNING: write header_size[%d] not matched [%zu]", n, sizeof(len));
return CUSTOM_SOCKET_ERROR;
}
MSG_FATAL("sockfd [%d] CLOSE_CONNECTION_BY_SIGNAL", sockfd);
return n;
} else if (n != sizeof(int)) {
- MSG_FATAL("WARNING: read header_size[%d] not matched [%d]", n, sizeof(int));
+ MSG_FATAL("WARNING: read header_size[%d] not matched [%zu]", n, sizeof(int));
return CUSTOM_SOCKET_ERROR;
}
MSG_FATAL("fd %d CLOSE_CONNECTION_BY_SIGNAL", fd);
return n;
} else if (n != sizeof(int)) {
- MSG_FATAL("readn %d(%d)", n, sizeof(int));
+ MSG_FATAL("readn %d(%zu)", n, sizeof(int));
return CUSTOM_SOCKET_ERROR;
}
int n = writen(fd, (const char*)&len, sizeof(len));
if (n != sizeof(len)) {
- MSG_FATAL("WARNING: write header_size[%d] not matched [%d]", n, sizeof(len));
+ MSG_FATAL("WARNING: write header_size[%d] not matched [%zu]", n, sizeof(len));
return CUSTOM_SOCKET_ERROR;
}
MSG_BEGIN();
if (pMsgData == NULL || pData == NULL) {
- MSG_DEBUG("param is NULL. pBody = %x, pData = %x", pMsgData, pData);
+ MSG_DEBUG("param is NULL. pBody = %p, pData = %s", pMsgData, pData);
return false;
}
offset += sizeof(MMS_MULTIPART_DATA_S);
MSG_DEBUG("SMIL file path = [%s]", pMsgData->smil->szFilePath);
- MSG_DEBUG("SMIL nMultipartDataLen = [%d]", pMsgData->smil->nMultipartDataLen);
+ MSG_DEBUG("SMIL nMultipartDataLen = [%lu]", pMsgData->smil->nMultipartDataLen);
if (pMsgData->smil->pMultipartData) {
memcpy(buf + offset, pMsgData->smil->pMultipartData, sizeof(char)*pMsgData->smil->nMultipartDataLen);
offset += sizeof(MMS_MULTIPART_DATA_S);
MSG_SEC_DEBUG("SMIL file path = [%s]", pMmsData->smil->szFilePath);
- MSG_DEBUG("SMIL nMultipartDataLen = [%d]", pMmsData->smil->nMultipartDataLen);
+ MSG_DEBUG("SMIL nMultipartDataLen = [%lu]", pMmsData->smil->nMultipartDataLen);
if (pMmsData->smil->nMultipartDataLen > 0) {
pMmsData->smil->pMultipartData = (char *)calloc(1, sizeof(char)*pMmsData->smil->nMultipartDataLen);
memset(pUCS2Text, 0x00, maxUCS2Length * sizeof(WCHAR));
MSG_DEBUG("srcTextLen = %d", srcTextLen);
- MSG_DEBUG("temp buffer size = %d", maxUCS2Length * sizeof(WCHAR));
+ MSG_DEBUG("temp buffer size = %lu", maxUCS2Length * sizeof(WCHAR));
MSG_DEBUG("max dest Length = %d", maxLength);
ucs2Length = convertUTF8ToUCS2((unsigned char*)pUCS2Text, maxUCS2Length * sizeof(WCHAR), pSrcText, srcTextLen);
memset(pUCS2Text, 0x00, maxUCS2Length * sizeof(WCHAR));
MSG_DEBUG("srcTextLen = %d", srcTextLen);
- MSG_DEBUG("temp buffer size = %d", maxUCS2Length * sizeof(WCHAR));
+ MSG_DEBUG("temp buffer size = %lu", maxUCS2Length * sizeof(WCHAR));
MSG_DEBUG("max dest Length = %d", maxLength);
ucs2Length = convertUTF8ToUCS2((unsigned char*)pUCS2Text, maxUCS2Length * sizeof(WCHAR), pSrcText, srcTextLen);
int ret = -1;
- MSG_DEBUG("[FILE] pFile [%p], offset [%d], origin [%d]", pFile, offset, origin);
+ MSG_DEBUG("[FILE] pFile [%p], offset [%ld], origin [%d]", pFile, offset, origin);
try {
ret = fseek(pFile, offset, origin); /* return 0, if success. */
size_t nWrite = 0;
- MSG_DEBUG("[FILE] pData [%p], size [%d], count [%d], pFile [%p]", pData, size, count, pFile);
+ MSG_DEBUG("[FILE] pData [%p], size [%lu], count [%lu], pFile [%p]", pData, size, count, pFile);
try {
nWrite = fwrite(pData, size, count, pFile);
/* Create Random Number */
srandom((unsigned int)ts.tv_nsec);
- MSG_DEBUG("ts.tv_nsec : %d", ts.tv_nsec);
+ MSG_DEBUG("ts.tv_nsec : %ld", ts.tv_nsec);
/* between 1 - 1000000000 */
snprintf(pFileName, MSG_FILENAME_LEN_MAX, "MSG_%lu.DATA", random()%1000000000+1);
bool MsgOpenAndReadFile(const char *pFileName, char **ppData, int *pDataSize)
{
if (!pFileName || !ppData || !pDataSize) {
- MSG_ERR("Invalid params!! pFileName=%x, ppData=%x, pDataSize=%x", pFileName, ppData, pDataSize);
+ MSG_ERR("Invalid params!! pFileName=%s, ppData=%s, pDataSize=%p", pFileName, *ppData, (void *)pDataSize);
return false;
}
}
MSG_DEBUG("MsgWriteDataFromEncodeBuffer:");
- MSG_DEBUG("pInBuffer %x", pInBuffer);
+ MSG_DEBUG("pInBuffer %s", pInBuffer);
MSG_DEBUG("pPtr %d", (*pPtr));
- MSG_DEBUG("before to fwite %x", pFile);
+ MSG_DEBUG("before to fwite %p", pFile);
if (MsgWriteFile(pInBuffer, sizeof(char), (*pPtr), pFile) != (size_t)(*pPtr)) {
MSG_FATAL("MsgWriteFile failed");
report_status[i] = (msg_struct_t)report_status_item;
- MSG_DEBUG("Report_type = %d, status addr = %s, status = %d, time = %d",
+ MSG_DEBUG("Report_type = %d, status addr = %s, status = %d, time = %ld",
report_status_info->type, report_status_info->addressVal,
report_status_info->status, report_status_info->statusTime);
}
return MSG_ERR_STORAGE_ERROR;
}
- MSG_SEC_DEBUG("Save text into file : size[%d] name[%s]", pMsgInfo->dataSize, fileName);
+ MSG_SEC_DEBUG("Save text into file : size[%lu] name[%s]", pMsgInfo->dataSize, fileName);
if (MsgWriteIpcFile(fileName, text, pMsgInfo->dataSize) == false) {
MSG_DEBUG("MsgWriteIpcFile error");
for (i = 0; i < size-1; i++) {
VDATA_TRACE(" i : %d", i);
- VDATA_TRACE(" for loop %d < %d, list[%d] : %p, list[%d].szName : %p", i, size, i, list[i], i, list[i].szName);
+ VDATA_TRACE(" for loop %d < %d, list[%d] : %d, list[%d].szName : %p", i, size, i, list[i].flag, i, list[i].szName);
VDATA_TRACE(" i : %d", i);
if (list[i].szName != NULL) {
VDATA_TRACE(" list[%d].szName != NULL", i);
while (pCurParam != NULL) {
pNextParam = pCurParam->pNext;
VDATA_TRACE("pNEXT ==> %p", pCurParam->pNext);
- VDATA_TRACE("pPARAM ==> %p", pCurParam->parameter);
- VDATA_TRACE("pVALUE ==> %p", pCurParam->paramValue);
+ VDATA_TRACE("pPARAM ==> %d", pCurParam->parameter);
+ VDATA_TRACE("pVALUE ==> %d", pCurParam->paramValue);
VDATA_TRACE("pCurParam : %p", pCurParam);
VDATA_TRACE("pCurParam->parameter : %d", pCurParam->parameter);
VDATA_TRACE("pCurParam->paramValue : %d", pCurParam->paramValue);
for (i = 0; i < size-1; i++) {
VDATA_TRACE(" i : %d", i);
- VDATA_TRACE(" for loop %d < %d, list[%d] : %p, list[%d].szName : %p", i, size, i, list[i], i, list[i].szName);
+ VDATA_TRACE(" for loop %d < %d, list[%d] : %d, list[%d].szName : %p", i, size, i, list[i].flag, i, list[i].szName);
VDATA_TRACE(" i : %d", i);
if (list[i].szName != NULL) {
VDATA_TRACE(" list[%d].szName != NULL", i);
while (pCurParam != NULL) {
pNextParam = pCurParam->pNext;
VDATA_TRACE("pNEXT ==> %p", pCurParam->pNext);
- VDATA_TRACE("pPARAM ==> %p", pCurParam->parameter);
- VDATA_TRACE("pVALUE ==> %p", pCurParam->paramValue);
+ VDATA_TRACE("pPARAM ==> %d", pCurParam->parameter);
+ VDATA_TRACE("pVALUE ==> %d", pCurParam->paramValue);
VDATA_TRACE("pCurParam : %p", pCurParam);
VDATA_TRACE("pCurParam->parameter : %d", pCurParam->parameter);
VDATA_TRACE("pCurParam->paramValue : %d", pCurParam->paramValue);
memset(pRes, '\0', ((len * 8 / 6) + 48));
_VB64Encode(pRes, pEncode, biLen);
- VDATA_TRACE("Origin Size: %d, Allocated Size %d, Coverted Size: %d\n", biLen, (len * 8 / 6) + 48, strlen(pRes));
+ VDATA_TRACE("Origin Size: %d, Allocated Size %d, Coverted Size: %lu\n", biLen, (len * 8 / 6) + 48, strlen(pRes));
VFREE(pEncode);
} else {
if ((pRes = (char *)calloc(1, len+30)) == NULL) {