Parse custom text header and ignore it.
Some MMS carrier append own custom header as text into PduData. We should parse it and ignore it at the moment. Change-Id: I4d6cf20f5cf99172ebbe310ab18101316eb04c77
This commit is contained in:
@@ -200,7 +200,18 @@ public class PduParser {
|
||||
PduHeaders headers = new PduHeaders();
|
||||
|
||||
while (keepParsing && (pduDataStream.available() > 0)) {
|
||||
pduDataStream.mark(1);
|
||||
int headerField = extractByteValue(pduDataStream);
|
||||
/* parse custom text header */
|
||||
if ((headerField >= TEXT_MIN) && (headerField <= TEXT_MAX)) {
|
||||
pduDataStream.reset();
|
||||
byte [] bVal = parseWapString(pduDataStream, TYPE_TEXT_STRING);
|
||||
if (LOCAL_LOGV) {
|
||||
Log.v(LOG_TAG, "TextHeader: " + new String(bVal));
|
||||
}
|
||||
/* we should ignore it at the moment */
|
||||
continue;
|
||||
}
|
||||
switch (headerField) {
|
||||
case PduHeaders.MESSAGE_TYPE:
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user