| 125 | } |
| 126 | |
| 127 | static bool DoStorageSearch_CKey(TCascSearch * pSearch, PCASC_FIND_DATA pFindData) |
| 128 | { |
| 129 | PCASC_CKEY_ENTRY pCKeyEntry; |
| 130 | TCascStorage * hs = pSearch->hs; |
| 131 | size_t nTotalItems = hs->CKeyArray.ItemCount(); |
| 132 | |
| 133 | // Reset the find data structure |
| 134 | ResetFindData(pFindData); |
| 135 | |
| 136 | // Check for CKeys that haven't been found yet |
| 137 | while(pSearch->nFileIndex < nTotalItems) |
| 138 | { |
| 139 | // Locate the n-th CKey entry. |
| 140 | pCKeyEntry = (PCASC_CKEY_ENTRY)hs->CKeyArray.ItemAt(pSearch->nFileIndex++); |
| 141 | //BREAK_ON_XKEY3(pCKeyEntry->CKey, 0x2B, 0xfc, 0xe4); |
| 142 | |
| 143 | // Only report files that are unreferenced by the ROOT handler |
| 144 | if(pCKeyEntry->IsFile() && pCKeyEntry->RefCount == 0) |
| 145 | { |
| 146 | return CopyCKeyEntryToFindData(pFindData, pCKeyEntry); |
| 147 | } |
| 148 | } |
| 149 | |
| 150 | // Nameless search ended |
| 151 | return false; |
| 152 | } |
| 153 | |
| 154 | static bool DoStorageSearch(TCascSearch * pSearch, PCASC_FIND_DATA pFindData) |
| 155 | { |
no test coverage detected