Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1d63cc3b authored by Todd Kennedy's avatar Todd Kennedy
Browse files

Set default reference ID

The reference ID may not be set [when the reference ID is 0x00], so,
we need to ensure it has a proper default value; instead of garbage

Change-Id: Ie1bcf062fbb1aab5832cf210f68b24732af5dc3b
Fixes: 74389717
Test: Run gReader and see that it doesn't crash
parent 17b2f5d4
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -837,7 +837,7 @@ static jint NativeGetResourceArray(JNIEnv* env, jclass /*clazz*/, jlong ptr, jin
    ResTable_config selected_config;
    selected_config.density = 0;
    uint32_t flags = bag->type_spec_flags;
    uint32_t ref;
    uint32_t ref = 0;
    ApkAssetsCookie cookie =
        assetmanager->ResolveReference(entry.cookie, &value, &selected_config, &flags, &ref);
    if (cookie == kInvalidCookie) {