[2] Avoid OOM in ApiDemos PduParser by using stream skip

Optimize skipWapValue in development ApiDemos copy of PduParser.java to use pduDataStream.skip(length) instead of allocating a byte array. This prevents potential OutOfMemoryErrors from malformed MMS PDUs with huge value lengths.

Also refactored repeated bounds-check logic into `isInvalidLength` helper.

Bug: 517377150
Flag: EXEMPT BUGFIX
Test: atest MmsTest PduParserTest WapPushOverSmsTest

CONV=9f66c987-4e37-4f71-bbaf-df4cf7f39fd8
TAG=agy
Cherrypick-From: https://googleplex-android-review.googlesource.com/q/commit:ceb926c9d643398f2404c31a2f6e00a3609f0092
Merged-In: I2ec3013ac5d7dee0d13ac1944591f8643445caa4
Change-Id: I2ec3013ac5d7dee0d13ac1944591f8643445caa4
1 file changed