summaryrefslogtreecommitdiff
path: root/libs/androidfw/ApkParsing.cpp
diff options
context:
space:
mode:
author Chet Haase <chet@google.com> 2023-01-04 20:56:32 +0000
committer Chet Haase <chet@google.com> 2023-01-05 01:28:02 +0000
commit4cf47f1b79d4b9ec4cc9dd19cb9a550d0bb21280 (patch)
tree69556394eb0baed4ad39b3531724e8404e71658a /libs/androidfw/ApkParsing.cpp
parent4dbae54d6e07b4ac34abad358be11293298b87d9 (diff)
Change behavior for next() and hasNext() for empty paths
Original behavior treated DONE like any other path verb, and threw an exception when querying an iterator that had already issued VERB_DONE. Also, hasNext() returned false after when next() would result in an exception. New behavior treats DONE as just informational: - An empty iterator, or one with no more verbs to iterate on, will always return VERB_DONE for next() - hasNext() will only return true when there are non-DONE verbs left to return from next(). Also, clarified docs for the verbs. Bug: 264437928 Test: PathTest and PathIteratorTest, including new test for hasNext() Change-Id: Icc0517ac3c2a346a3271ff2f78e7629e4ebb5d0a
Diffstat (limited to 'libs/androidfw/ApkParsing.cpp')
0 files changed, 0 insertions, 0 deletions