am 5e7b7cd6: Merge "range checking for tnf" into gingerbread

Merge commit '5e7b7cd65bea53357ecad68a31a52883897c824b' into gingerbread-plus-aosp

* commit '5e7b7cd65bea53357ecad68a31a52883897c824b':
  range checking for tnf
This commit is contained in:
Nick Kralevich
2010-10-15 18:41:59 -07:00
committed by Android Git Automerger

View File

@@ -168,6 +168,10 @@ public class NdefRecord implements Parcelable {
throw new IllegalArgumentException("Illegal null argument");
}
if (tnf < 0 || tnf > 0x07) {
throw new IllegalArgumentException("TNF out of range " + tnf);
}
/* generate flag */
byte flags = FLAG_MB | FLAG_ME;