mirror of
https://github.com/crskycode/GARbro.git
synced 2026-07-08 01:30:18 +08:00
(AImageReader): slight fault tolerance.
This commit is contained in:
@@ -210,7 +210,7 @@ namespace GameRes.Formats.Cyberworks
|
|||||||
if (has_alpha || (bit & rgb_map[bit_src]) != 0)
|
if (has_alpha || (bit & rgb_map[bit_src]) != 0)
|
||||||
{
|
{
|
||||||
m_input.Read (m_output, dst, 3);
|
m_input.Read (m_output, dst, 3);
|
||||||
if (has_alpha)
|
if (has_alpha && alpha_src < alpha.Length)
|
||||||
{
|
{
|
||||||
m_output[dst+3] = alpha[alpha_src];
|
m_output[dst+3] = alpha[alpha_src];
|
||||||
alpha_src += 3;
|
alpha_src += 3;
|
||||||
|
|||||||
Reference in New Issue
Block a user