OSDN Git Service

Change DCS of MO SMS to the correct value for UCS-2 encoding.
authorsj0110.kim@samsung.com(sophia kim) <sj0110.kim@samsung.com>
Thu, 29 Sep 2011 12:20:30 +0000 (21:20 +0900)
committerJake Hamby <jhamby@google.com>
Tue, 11 Oct 2011 22:29:20 +0000 (15:29 -0700)
An incorrect value for TP-Data-Coding-Scheme was used for MO SMS with
UCS-2 encoding. According to 3GPP TS 23.038 section 4, when bit 4 is
set to 0, bits 0 and 1 are reserved and have no message class meaning.
We were setting those bits to 1, when they should be set to 0.

This change is required to pass a GCF test case.

Change-Id: If47361f95b0e14accc6220854783dcff3d82abf6

telephony/java/com/android/internal/telephony/gsm/SmsMessage.java

index ea030e6..2da9642 100644 (file)
@@ -300,8 +300,8 @@ public class SmsMessage extends SmsMessageBase {
                 return null;
             }
             // TP-Data-Coding-Scheme
-            // Class 3, UCS-2 encoding, uncompressed
-            bo.write(0x0b);
+            // UCS-2 encoding, uncompressed
+            bo.write(0x08);
         }
 
         // (no TP-Validity-Period)