summaryrefslogtreecommitdiff
path: root/rs/java/android/renderscript/ProgramFragmentFixedFunction.java
diff options
context:
space:
mode:
authorTaesu Lee <taesu82.lee@samsung.com>2019-01-31 14:38:56 +0900
committerTaesu Lee <taesu82.lee@samsung.com>2019-02-01 08:51:56 +0900
commit309fc2d4a804d6c46c6df183f616e325759762ff (patch)
treed29c9e772bd35e8d1a32dd863901de07b1e6c4af /rs/java/android/renderscript/ProgramFragmentFixedFunction.java
parent643e60b0fed9d113a4a35847f61a98c2f0e3e6f9 (diff)
Fix wrong userData length and excessive userData issues
Added checking size excess in encodeUCS2() and an exception cause in EncodeException to distinguish between unencodable char and size excess. It will prevent wrong userData length and excessive userData issues during encoding userData. Please see below one issue scenario. stringToGsm7BitPackedWithHeader() throws an EncodeException when septeCount > 255. The EncodeException is caught and encoding again through encodeUCS2(). However, the length of encoded userData as UCS-2 is converted as Byte without checking size excess. Thus first byte of userData will be wrong and total userData will exceed maximum User Data. Test: Manual Change-Id: Ib6df5484072d77548e8adcbcbd15ad7a401c99f8 Signed-off-by: Taesu Lee <taesu82.lee@samsung.com>
Diffstat (limited to 'rs/java/android/renderscript/ProgramFragmentFixedFunction.java')
0 files changed, 0 insertions, 0 deletions