Skip to content
Snippets Groups Projects
Forked from Dhina17 / platform_frameworks_base
2371 commits behind the upstream repository.
  • Leon Scroggins III's avatar
    3eb6c88b
    Check for (and clear) Exceptions thrown by TransferParameters · 3eb6c88b
    Leon Scroggins III authored
    In GraphicsJNI::getColorSpace, which returns an
    android.graphics.ColorSpace for a Bitmap, Skia reads the encoded
    transfer function which then gets passed to the TransferParameters
    constructor. It's possible for that constructor to throw an Exception,
    in which case we cannot call JNI functions without handling the
    Exception. Clear it and return null, since we are now unable to create
    an android.graphics.ColorSpace.
    
    Bug: 198155681
    Test: I805aba8c078aac71d92ea71a199c2e1fe52df8fd
    Flag: EXEMPT trivial bug fix
    Change-Id: Ib1f7cbcc62a4722a2379b111838584cc4b6a36cc
    3eb6c88b
    History
    Check for (and clear) Exceptions thrown by TransferParameters
    Leon Scroggins III authored
    In GraphicsJNI::getColorSpace, which returns an
    android.graphics.ColorSpace for a Bitmap, Skia reads the encoded
    transfer function which then gets passed to the TransferParameters
    constructor. It's possible for that constructor to throw an Exception,
    in which case we cannot call JNI functions without handling the
    Exception. Clear it and return null, since we are now unable to create
    an android.graphics.ColorSpace.
    
    Bug: 198155681
    Test: I805aba8c078aac71d92ea71a199c2e1fe52df8fd
    Flag: EXEMPT trivial bug fix
    Change-Id: Ib1f7cbcc62a4722a2379b111838584cc4b6a36cc
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
Graphics.cpp 32.63 KiB