Fix default return code for getResource

Reorganization of getResource to allow for other densities accidentally
overrode the default return code for getResource from BAD_VALUE to
BAD_INDEX. This corrects the default return to BAD_VALUE which restores
other things to working.

Bug: 3155824
Change-Id: I13dafff85bc6978c5f5435fc09ab0474c7885c4d
This commit is contained in:
Kenny Root 2010-11-02 11:27:21 -07:00 committed by Alex Ray
parent 328f501eb9
commit 3a91fca00c

View file

@ -1949,7 +1949,7 @@ ssize_t ResTable::getResource(uint32_t resID, Res_value* outValue, bool mayBeBag
desiredConfig = overrideConfig;
}
ssize_t rc = BAD_INDEX;
ssize_t rc = BAD_VALUE;
size_t ip = grp->packages.size();
while (ip > 0) {
ip--;