CPLFindFile */
| 162 | |
| 163 | /** CPLFindFile */ |
| 164 | const char *CPLFindFile(const char *pszClass, const char *pszBasename) |
| 165 | |
| 166 | { |
| 167 | FindFileTLS *pTLSData = CPLFinderInit(); |
| 168 | if (pTLSData == nullptr) |
| 169 | return nullptr; |
| 170 | |
| 171 | for (int i = pTLSData->nFileFinders - 1; i >= 0; i--) |
| 172 | { |
| 173 | const char *pszResult = |
| 174 | (pTLSData->papfnFinders[i])(pszClass, pszBasename); |
| 175 | if (pszResult != nullptr) |
| 176 | return pszResult; |
| 177 | } |
| 178 | |
| 179 | return nullptr; |
| 180 | } |
| 181 | |
| 182 | /************************************************************************/ |
| 183 | /* CPLPushFileFinder() */ |
no test coverage detected