Merge change 25839 into eclair

* changes:
  Fix potential ArrayIndexOutOfBoundsException.
This commit is contained in:
Android (Google) Code Review
2009-09-18 20:09:34 -04:00

View File

@@ -383,7 +383,7 @@ public abstract class SmsMessageBase {
* 2. [x@y][ ]/[body] * 2. [x@y][ ]/[body]
*/ */
String[] parts = messageBody.split("( /)|( )", 2); String[] parts = messageBody.split("( /)|( )", 2);
if (parts.length < 1) return; if (parts.length < 2) return;
emailFrom = parts[0]; emailFrom = parts[0];
emailBody = parts[1]; emailBody = parts[1];
isEmail = true; isEmail = true;