Check for URL pattern. Note that the string may be terminated by CASC_PARAM_SEPARATOR instead of '\0'
| 1265 | |
| 1266 | // Check for URL pattern. Note that the string may be terminated by CASC_PARAM_SEPARATOR instead of '\0' |
| 1267 | static bool IsUrl(LPCTSTR szString) |
| 1268 | { |
| 1269 | while(szString[0] != 0 && szString[0] != CASC_PARAM_SEPARATOR) |
| 1270 | { |
| 1271 | // Check for "://" |
| 1272 | if(!_tcsncmp(szString, _T("://"), 3)) |
| 1273 | return true; |
| 1274 | |
| 1275 | // Dot or slash both indicate an URL |
| 1276 | if(szString[0] == '.' || szString[0] == '/') |
| 1277 | return true; |
| 1278 | |
| 1279 | szString++; |
| 1280 | } |
| 1281 | return false; |
| 1282 | } |
| 1283 | |
| 1284 | static LPTSTR GetNextParam(LPTSTR szParamsPtr, bool bMustBeUrl = false) |
| 1285 | { |