57#define ENTRY_START_OFFSET 0x4000
59#define MAX_DIR_NO 0x20
61#define HASHTABLE_SIZE 448
62#define HASHTABLE_NUM_ENTRIES 64
63#define HASHTABLE_BLOCKSIZE (HASHTABLE_SIZE / HASHTABLE_NUM_ENTRIES)
64#define ALLOCATION_TABLE_OFFSET 0x250
65#define ALLOCATION_TABLE_SIZE (ENTRY_START_OFFSET - ALLOCATION_TABLE_OFFSET)
66#define MIN_BLOCK_NO 0x80
67#define MAX_BLOCK_NO (ALLOCATION_TABLE_SIZE * CHAR_BIT)
68#define FILE_SIZE(blocks) ((blocks) * BLOCKSIZE + ENTRY_START_OFFSET)
70#define HASHTABLE_URL 0
71#define HASHTABLE_DEL 1
72#define HASHTABLE_LOCK 2
73#define HASHTABLE_FREE 3
74#define HASHTABLE_REDR 5
75#define HASHTABLE_FLAG_BITS 6
77#define PENDING_DELETE_CACHE_ENTRY 0x00400000
78#define INSTALLED_CACHE_ENTRY 0x10000000
79#define GET_INSTALLED_ENTRY 0x200
80#define CACHE_CONTAINER_NO_SUBDIR 0xFE
82#define CACHE_HEADER_DATA_ROOT_LEAK_OFFSET 0x16
84#define FILETIME_SECOND 10000000
86#define DWORD_SIG(a,b,c,d) (a | (b << 8) | (c << 16) | (d << 24))
87#define URL_SIGNATURE DWORD_SIG('U','R','L',' ')
88#define REDR_SIGNATURE DWORD_SIG('R','E','D','R')
89#define LEAK_SIGNATURE DWORD_SIG('L','E','A','K')
90#define HASH_SIGNATURE DWORD_SIG('H','A','S','H')
92#define DWORD_ALIGN(x) ( (DWORD)(((DWORD)(x)+sizeof(DWORD)-1)/sizeof(DWORD))*sizeof(DWORD) )
94#define URLCACHE_FIND_ENTRY_HANDLE_MAGIC 0xF389ABCD
232 return (allocation_table[block_number/
CHAR_BIT] &
mask) == 0;
305 (*entry)->blocks_used = blocks_needed;
307 header->blocks_in_use += blocks_needed;
365 (*hash_table)->next = 0;
366 (*hash_table)->id = hash_table_prev ? hash_table_prev->
id+1 : 0;
387 for (; *lpszPath; lpszPath++)
389 if (*lpszPath ==
'\\')
445 header->capacity_in_blocks = blocks_no;
459 header->capacity_in_blocks = blocks_no;
461 header->cache_limit.QuadPart = 0x07ff5400;
467 L"Software\\Microsoft\\Windows\\CurrentVersion\\Internet Settings\\Cache\\Content", &
key) ==
ERROR_SUCCESS) {
480 dir_name = dir_path +
lstrlenW(dir_path);
486 header->directory_data[
i].files_no = 0;
500 for(
k = 0;
k < 8; ++
k) {
509 dir_name[
k] =
'0' +
r;
511 dir_name[
k] =
'A' + (
r - 10);
520 for (
k = 0;
k < 8; ++
k)
521 header->directory_data[
i].name[
k] = dir_name[
k];
561 for(
i=0;
i<
header->capacity_in_blocks/8;
i++) {
562 for(count_bits =
header->allocation_table[
i]; count_bits!=0; count_bits>>=1) {
571 if(
header->allocation_table[
i])
612 TRACE(
"Could not open or create cache index file \"%s\"\n",
debugstr_w(index_path));
643 WARN(
"detected old or broken index.dat file\n");
684 int cache_prefix_len =
strlen(cache_prefix);
696 if (!pContainer->
path)
744 const WCHAR *shpath_suffix;
745 const char *cache_prefix;
746 DWORD default_entry_type;
747 } DefaultContainerData[] =
759 ERR(
"Environment variable 'USERPROFILE' does not exist!\n");
773 ERR(
"Couldn't get path for default container %lu\n",
i);
777 suffix_len =
lstrlenW(DefaultContainerData[
i].shpath_suffix);
781 ERR(
"Path too long\n");
788 lstrcpyW(wszMutexName, wszCachePath);
792 memcpy(wszCachePath +
path_len + 1, DefaultContainerData[
i].shpath_suffix, (suffix_len + 1) *
sizeof(
WCHAR));
793 wszCachePath[
path_len + suffix_len + 1] =
'\\';
794 wszCachePath[
path_len + suffix_len + 2] =
'\0';
798 NULL, 0,
NULL, &def_char) || def_char)
805 NULL, 0,
NULL, &def_char) || def_char)
806 ERR(
"Can't create container path accessible by ANSI functions\n");
812 DefaultContainerData[
i].default_entry_type, wszMutexName);
854 ERR(
"no container found\n");
866 if (search_pattern &&
index > 0)
1008 if (trunc_name && nRequired >= *lpBufferSize)
1009 nRequired = *lpBufferSize;
1010 if (nRequired <= *lpBufferSize)
1018 wszPath[dir_len +
path_len] =
'\\';
1027 wszPath[*lpBufferSize/
sizeof(
WCHAR)-1] = 0;
1028 *lpBufferSize = nRequired;
1031 *lpBufferSize = nRequired;
1056 int path_len, file_name_len, dir_len;
1065 file_name_len =
strlen(szLocalFileName) + 1 ;
1071 nRequired = (
path_len + dir_len + file_name_len) *
sizeof(
char);
1072 if (nRequired <= *lpBufferSize)
1080 *lpBufferSize = nRequired;
1083 *lpBufferSize = nRequired;
1094 *fatdate = *fattime = 0;
1140 header->exempt_usage.QuadPart = 0;
1147 header->cache_usage.QuadPart = 0;
1197 WARN(
"index file has maximal size\n");
1220 if (!fatdate && !fattime)
1232 memset(&uc, 0,
sizeof(uc));
1259 decoded_url ? decoded_url+
len :
NULL, decoded_len);
1267 decoded_len -= part_len;
1271 -1, decoded_url ? decoded_url+
len :
NULL, decoded_len);
1295 if(*info_size >=
size) {
1320 if(*info_size >=
size) {
1321 DWORD url_size = url_len * (unicode ?
sizeof(
WCHAR) :
sizeof(
CHAR));
1335 LONG file_name_size;
1338 file_name_size = *info_size-
size;
1345 size += file_name_size;
1360 size += header_len * (unicode ?
sizeof(
WCHAR) :
sizeof(
CHAR));
1362 if(*info_size >=
size) {
1363 DWORD header_size = header_len * (unicode ?
sizeof(
WCHAR) :
sizeof(
CHAR));
1385 if(*info_size >=
size) {
1399 if(
size > *info_size) {
1429 FIXME(
"CACHE_ENTRY_HEADERINFO_FC unimplemented\n");
1454 static const unsigned char lookupTable[256] =
1456 0x01, 0x0E, 0x6E, 0x19, 0x61, 0xAE, 0x84, 0x77,
1457 0x8A, 0xAA, 0x7D, 0x76, 0x1B, 0xE9, 0x8C, 0x33,
1458 0x57, 0xC5, 0xB1, 0x6B, 0xEA, 0xA9, 0x38, 0x44,
1459 0x1E, 0x07, 0xAD, 0x49, 0xBC, 0x28, 0x24, 0x41,
1460 0x31, 0xD5, 0x68, 0xBE, 0x39, 0xD3, 0x94, 0xDF,
1461 0x30, 0x73, 0x0F, 0x02, 0x43, 0xBA, 0xD2, 0x1C,
1462 0x0C, 0xB5, 0x67, 0x46, 0x16, 0x3A, 0x4B, 0x4E,
1463 0xB7, 0xA7, 0xEE, 0x9D, 0x7C, 0x93, 0xAC, 0x90,
1464 0xB0, 0xA1, 0x8D, 0x56, 0x3C, 0x42, 0x80, 0x53,
1465 0x9C, 0xF1, 0x4F, 0x2E, 0xA8, 0xC6, 0x29, 0xFE,
1466 0xB2, 0x55, 0xFD, 0xED, 0xFA, 0x9A, 0x85, 0x58,
1467 0x23, 0xCE, 0x5F, 0x74, 0xFC, 0xC0, 0x36, 0xDD,
1468 0x66, 0xDA, 0xFF, 0xF0, 0x52, 0x6A, 0x9E, 0xC9,
1469 0x3D, 0x03, 0x59, 0x09, 0x2A, 0x9B, 0x9F, 0x5D,
1470 0xA6, 0x50, 0x32, 0x22, 0xAF, 0xC3, 0x64, 0x63,
1471 0x1A, 0x96, 0x10, 0x91, 0x04, 0x21, 0x08, 0xBD,
1472 0x79, 0x40, 0x4D, 0x48, 0xD0, 0xF5, 0x82, 0x7A,
1473 0x8F, 0x37, 0x69, 0x86, 0x1D, 0xA4, 0xB9, 0xC2,
1474 0xC1, 0xEF, 0x65, 0xF2, 0x05, 0xAB, 0x7E, 0x0B,
1475 0x4A, 0x3B, 0x89, 0xE4, 0x6C, 0xBF, 0xE8, 0x8B,
1476 0x06, 0x18, 0x51, 0x14, 0x7F, 0x11, 0x5B, 0x5C,
1477 0xFB, 0x97, 0xE1, 0xCF, 0x15, 0x62, 0x71, 0x70,
1478 0x54, 0xE2, 0x12, 0xD6, 0xC7, 0xBB, 0x0D, 0x20,
1479 0x5E, 0xDC, 0xE0, 0xD4, 0xF7, 0xCC, 0xC4, 0x2B,
1480 0xF9, 0xEC, 0x2D, 0xF4, 0x6F, 0xB6, 0x99, 0x88,
1481 0x81, 0x5A, 0xD9, 0xCA, 0x13, 0xA5, 0xE7, 0x47,
1482 0xE6, 0x8E, 0x60, 0xE3, 0x3E, 0xB3, 0xF6, 0x72,
1483 0xA2, 0x35, 0xA0, 0xD7, 0xCD, 0xB4, 0x2F, 0x6D,
1484 0x2C, 0x26, 0x1F, 0x95, 0x87, 0x00, 0xD8, 0x34,
1485 0x3F, 0x17, 0x25, 0x45, 0x27, 0x75, 0x92, 0xB8,
1486 0xA3, 0xC8, 0xDE, 0xEB, 0xF8, 0xF3, 0xDB, 0x0A,
1487 0x98, 0x83, 0x7B, 0xE5, 0xCB, 0x4C, 0x78, 0xD1
1493 key[
i] = lookupTable[(*lpszKey +
i) & 0xFF];
1495 for (lpszKey++; *lpszKey; lpszKey++)
1498 key[
i] = lookupTable[*lpszKey ^
key[
i]];
1536 if (pHashEntry->
id !=
id++)
1538 ERR(
"Error: not right hash table number (%ld) expected %ld\n", pHashEntry->
id,
id);
1559 *ppHashEntry = pHashElement;
1626 pHashPrev = pHashEntry;
1628 if (pHashEntry->
id !=
id++)
1630 ERR(
"not right hash table number (%ld) expected %ld\n", pHashEntry->
id,
id);
1646 pHashElement->
offset = dwOffsetEntry;
1675 TRACE(
"looking at hash table number %ld\n", (*ppHashEntry)->id);
1676 if ((*ppHashEntry)->id != *
id)
1681 ERR(
"Error: not right signature (\"%.4s\") - expected \"HASH\"\n", (
LPCSTR)&(*ppHashEntry)->header.signature);
1686 TRACE(
"hash table number %ld found\n", *
id);
1797 FIXME(
"ignoring unsupported flags: %lx\n",
flags);
1823 FIXME(
"Trying to retrieve entry of unknown format %s\n",
1868 ERR(
"Reserved value was not 0\n");
1883 LPDWORD lpdwCacheEntryInfoBufferSize)
1897 memset(&uc, 0,
sizeof(uc));
1907 encoded_url, encoded_len,
NULL,
NULL);
1935 encoded_len -= part_len;
1984 ERR(
"Reserved value was not 0\n");
1990 dwFlags &= ~GET_INSTALLED_ENTRY;
2007 LPDWORD lpdwCacheEntryInfoBufferSize)
2018 DWORD dwFieldControl)
2026 TRACE(
"(%s, %p, 0x%08lx)\n",
debugstr_a(lpszUrlName), lpCacheEntryInfo, dwFieldControl);
2074 DWORD dwFieldControl)
2126 FIXME(
"Trying to retrieve entry of unknown format %s\n",
2144 size, url_entry, unicode);
2171 lpdwCacheEntryInfoBufferSize,
FALSE);
2189 lpdwCacheEntryInfoBufferSize,
TRUE);
2203 FIXME(
"Trying to delete entry of unknown format %s\n",
2212 TRACE(
"Trying to delete locked entry\n");
2260 if(!*hash_table_off) {
2261 *hash_table_off =
header->hash_table_off;
2262 *hash_table_entry = 0;
2266 if(*hash_table_off >=
header->size) {
2267 *hash_table_off = 0;
2275 *hash_table_off = 0;
2281 *hash_table_off = hashtable_entry->
next;
2282 if(!*hash_table_off) {
2283 *hash_table_off = 0;
2288 *hash_table_entry = 0;
2295 (*hash_table_entry)++;
2299 (*hash_table_entry)++;
2302 *hash_table_off = 0;
2334 rating = 400*60*60*24/(60*60*24+
time.QuadPart);
2346 return *(
const DWORD*)p1 - *(
const DWORD*)p2;
2420 DWORD delete_factor, hash_table_off, hash_table_entry;
2439 desired_size =
header->cache_limit.QuadPart*(100-
size)/100;
2440 cur_size =
header->cache_usage.QuadPart+
header->exempt_usage.QuadPart;
2441 if(cur_size <= desired_size)
2444 delete_factor = (cur_size-desired_size)*100/cur_size;
2446 if(!delete_factor) {
2452 hash_table_entry = 0;
2458 WARN(
"only url entries are currently supported\n");
2467 if(
rate[rate_no] != -1)
2472 TRACE(
"nothing to delete\n");
2479 delete_factor = delete_factor*rate_no/100;
2480 delete_factor =
rate[delete_factor];
2481 TRACE(
"deleting files with rating %ld or less\n", delete_factor);
2496 if(
header->cache_usage.QuadPart+
header->exempt_usage.QuadPart <= desired_size)
2502 TRACE(
"got dll_unload_event - finishing\n");
2510 TRACE(
"cache size after cleaning 0x%s/0x%s\n",
2551 ERR(
"dwReserved != 0\n");
2634 LONG full_path_len, ext_len = 0;
2644 memset(&uc, 0,
sizeof(uc));
2683 generate_name =
TRUE;
2707 WARN(
"Failed to get full path for filename %s, needed %lu bytes.\n",
2712 full_path_len = full_path_len/
sizeof(
WCHAR) - 1;
2722 for(
p=extW; *
p;
p++) {
2732 if(
p[-1]==
' ' ||
p[-1]==
'.')
2738 if(!generate_name && full_path_len+5+ext_len>=
MAX_PATH) {
2739 full_path_len =
MAX_PATH-5-ext_len-1;
2742 for(
i=0;
i<255 && !generate_name;
i++) {
2743 wsprintfW(full_path+full_path_len,
L"[%u]%s",
i, extW);
2753 if(full_path_len+8+ext_len >=
MAX_PATH)
2754 full_path_len =
MAX_PATH-8-ext_len-1;
2758 lstrcpyW(full_path+full_path_len+8, extW);
2760 for(
i=0;
i<255;
i++) {
2767 for(
j=0;
j<8;
j++) {
2770 full_path[full_path_len+
j] = (
r < 10 ?
'0' +
r :
'A' +
r - 10);
2781 WARN(
"Could not find a unique filename\n");
2817 if(lpszFileExtension) {
2836 BYTE *header_info,
DWORD header_size,
const char *file_ext,
2837 const char *original_url)
2844 DWORD url_entry_offset;
2846 DWORD file_name_off = 0;
2847 DWORD header_info_off = 0;
2848 DWORD file_ext_off = 0;
2852 char file_name_no_container[
MAX_PATH];
2853 char *local_file_name = 0;
2855 DWORD exempt_delta = 0;
2858 TRACE(
"(%s, %s, ..., ..., %lx, %p, %ld, %s, %s)\n",
debugstr_a(
url),
debugstr_w(
file_name),
2866 WARN(
": original_url ignored\n");
2868 memset(&file_attr, 0,
sizeof(file_attr));
2895 TRACE(
"Trying to overwrite locked entry\n");
2925 local_file_name = file_name_no_container;
2928 for(dir_id = 0; dir_id <
header->dirs_no; dir_id++) {
2949 file_name_off =
size;
2952 if(header_info && header_size) {
2953 header_info_off =
size;
2956 if(file_ext && (file_ext_off =
strlen(file_ext))) {
2959 file_ext_off =
size;
2990 exempt_delta = 86400;
3007 url_entry->
unk1 = 0;
3008 url_entry->
unk2 = 0;
3009 url_entry->
unk3 = 0x60;
3010 url_entry->
unk4 = 0;
3011 url_entry->
unk5 = 0x1010;
3012 url_entry->
unk7 = 0;
3013 url_entry->
unk8 = 0;
3020 memcpy((
LPBYTE)url_entry + header_info_off, header_info, header_size);
3046 if(
header->cache_usage.QuadPart+
header->exempt_usage.QuadPart >
header->cache_limit.QuadPart)
3063 if(lpszLocalFileName) {
3070 CacheEntryType, lpHeaderInfo, dwHeaderSize, lpszFileExtension, lpszOriginalUrl);
3094 dwHeaderSize =
strlen(header_info);
3097 if(lpszFileExtension) {
3139 ERR(
"dwReserved != 0\n");
3172 TRACE(
"(%s, %p, %p, %x, 0x%08lx)\n",
debugstr_a(lpszUrlName), lpCacheEntryInfo,
3173 lpdwCacheEntryInfoBufferSize, fRandomRead,
dwReserved);
3218 TRACE(
"(%s, %p, %p, %x, 0x%08lx)\n",
debugstr_w(lpszUrlName), lpCacheEntryInfo,
3219 lpdwCacheEntryInfoBufferSize, fRandomRead,
dwReserved);
3267 ERR(
"dwReserved != 0\n");
3352 FIXME(
"(0x%08lx, 0x%08lx) stub\n", d1, d2);
3358 FIXME(
"(0x%08lx, 0x%08lx) stub\n", d1, d2);
3368 FIXME(
"(0x%08lx, 0x%08lx, 0x%08lx, 0x%08lx, 0x%08lx, 0x%08lx, 0x%08lx, 0x%08lx) stub\n",
3369 d1, d2, d3, d4, d5, d6, d7, d8);
3379 FIXME(
"(0x%08lx, 0x%08lx, 0x%08lx, 0x%08lx, 0x%08lx, 0x%08lx, 0x%08lx, 0x%08lx) stub\n",
3380 d1, d2, d3, d4, d5, d6, d7, d8);
3389 FIXME(
"(%p, %p, %p, 0x%08lx) stub\n", p1, p2, p3, d1 );
3398 FIXME(
"(%p, %p, %p, 0x%08lx) stub\n", p1, p2, p3, d1 );
3421 LPCSTR lpszUrlSearchPattern,
3426 LPDWORD lpdwFirstCacheEntryInfoBufferSize,
3432 FIXME(
"(%s, 0x%08lx, 0x%08lx, 0x%s, %p, %p, %p, %p, %p) stub\n",
debugstr_a(lpszUrlSearchPattern),
3434 lpdwFirstCacheEntryInfoBufferSize,
lpReserved, pcbReserved2,lpReserved3);
3445 LPDWORD lpdwFirstCacheEntryInfoBufferSize,
3451 FIXME(
"(%s, 0x%08lx, 0x%08lx, 0x%s, %p, %p, %p, %p, %p) stub\n",
debugstr_w(lpszUrlSearchPattern),
3453 lpdwFirstCacheEntryInfoBufferSize,
lpReserved, pcbReserved2,lpReserved3);
3467 TRACE(
"(%s, %p, %p)\n",
debugstr_a(lpszUrlSearchPattern), lpFirstCacheEntryInfo, lpdwFirstCacheEntryInfoBufferSize);
3469 pEntryHandle =
malloc(
sizeof(*pEntryHandle));
3474 if (lpszUrlSearchPattern)
3494 return pEntryHandle;
3506 TRACE(
"(%s, %p, %p)\n",
debugstr_w(lpszUrlSearchPattern), lpFirstCacheEntryInfo, lpdwFirstCacheEntryInfoBufferSize);
3508 pEntryHandle =
malloc(
sizeof(*pEntryHandle));
3513 if (lpszUrlSearchPattern)
3533 return pEntryHandle;
3539 LPDWORD lpdwNextCacheEntryInfoBufferSize,
3582 TRACE(
"Found URL: %s\n",
3584 TRACE(
"Header info: %s\n",
3591 lpNextCacheEntryInfo,
3592 lpdwNextCacheEntryInfoBufferSize,
3625 LPDWORD lpdwNextCacheEntryInfoBufferSize)
3627 TRACE(
"(%p, %p, %p)\n", hEnumHandle, lpNextCacheEntryInfo, lpdwNextCacheEntryInfoBufferSize);
3630 lpdwNextCacheEntryInfoBufferSize,
FALSE );
3639 LPDWORD lpdwNextCacheEntryInfoBufferSize
3642 TRACE(
"(%p, %p, %p)\n", hEnumHandle, lpNextCacheEntryInfo, lpdwNextCacheEntryInfoBufferSize);
3646 lpdwNextCacheEntryInfoBufferSize,
TRUE );
3656 TRACE(
"(%p)\n", hEnumHandle);
3674 FIXME(
"(0x%08lx, 0x%08lx, %p, 0x%08lx, %p, %p) stub\n",
dwFlags, dwFilter, lpSearchCondition,
3682 LPDWORD lpdwFirstCacheEntryInfoBufferSize,
3688 FIXME(
"(%p, %p, %p, %p, %p, %p) stub\n", hEnumHandle, lpFirstCacheEntryInfo, lpdwFirstCacheEntryInfoBufferSize,
3696 LPDWORD lpdwFirstCacheEntryInfoBufferSize,
3702 FIXME(
"(%p, %p, %p, %p, %p, %p) stub\n", hEnumHandle, lpFirstCacheEntryInfo, lpdwFirstCacheEntryInfoBufferSize,
3729 FIXME(
"(0x%s, 0x%08lx, %p) stub\n",
3752 FIXME(
"(%s, 0x%08lx, 0x%s, %p, 0x%08lx, %p) stub\n",
3754 pbGroupAttributes, cbGroupAttributes,
lpReserved);
3767 FIXME(
"(%s, 0x%08lx, 0x%s, %p, 0x%08lx, %p) stub\n",
3769 pbGroupAttributes, cbGroupAttributes,
lpReserved);
3830 info->dwContainer = 0;
3832 info->dwReserved4 = 0;
3834 info->dwSyncMode = 0;
3835 info->dwNumCachePaths = 1;
3836 info->dwNormalUsage = 0;
3837 info->dwExemptUsage = 0;
3872 info->dwNumCachePaths =
infoW.dwNumCachePaths;
3873 info->dwNormalUsage =
infoW.dwNormalUsage;
3874 info->dwExemptUsage =
infoW.dwExemptUsage;
3885 FIXME(
"(0x%s, 0x%08lx, 0x%08lx, %p, %p, %p) stub\n",
3895 FIXME(
"(0x%s, 0x%08lx, 0x%08lx, %p, %p, %p) stub\n",
3904 FIXME(
"(0x%s, 0x%08lx, 0x%08lx, %p, %p) stub\n",
3912 FIXME(
"(0x%s, 0x%08lx, 0x%08lx, %p, %p) stub\n",
3919 FIXME(
"(%p, 0x%08lx) stub\n", lpCacheConfigInfo, dwFieldControl);
3925 FIXME(
"(%p, 0x%08lx) stub\n", lpCacheConfigInfo, dwFieldControl);
3983 if (!
url || !pftLastModified)
3991 memset(pftLastModified, 0,
sizeof(*pftLastModified));
3997 memset(pftLastModified, 0,
sizeof(*pftLastModified));
4003 memset(pftLastModified, 0,
sizeof(*pftLastModified));
4010 memset(pftLastModified, 0,
sizeof(*pftLastModified));
4011 TRACE(
"entry %s not found!\n",
url);
4020 memset(pftLastModified, 0,
sizeof(*pftLastModified));
4083 FIXME(
"(%p %lx %lx %lx %lx %lx)\n",
a,
b,
c,
d,
e,
f);
INT WINAPI IdnToAscii(DWORD dwFlags, LPCWSTR lpUnicodeCharStr, INT cchUnicodeChar, LPWSTR lpASCIICharStr, INT cchASCIIChar)
INT WINAPI IdnToUnicode(DWORD dwFlags, LPCWSTR lpASCIICharStr, INT cchASCIIChar, LPWSTR lpUnicodeCharStr, INT cchUnicodeChar)
static char * strdupWtoA(const WCHAR *str)
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
static void list_remove(struct list_entry *entry)
static int list_empty(struct list_entry *head)
static void list_add_head(struct list_entry *head, struct list_entry *entry)
#define RegCloseKey(hKey)
#define ERROR_NOT_ENOUGH_MEMORY
#define ERROR_INSUFFICIENT_BUFFER
size_t const allocation_size
LONG WINAPI RegOpenKeyW(HKEY hKey, LPCWSTR lpSubKey, PHKEY phkResult)
LONG WINAPI RegQueryValueExW(_In_ HKEY hkeyorg, _In_ LPCWSTR name, _In_ LPDWORD reserved, _In_ LPDWORD type, _In_ LPBYTE data, _In_ LPDWORD count)
static WCHAR * strdupAtoW(const char *str)
#define ERROR_INVALID_PARAMETER
#define INVALID_SET_FILE_POINTER
#define GetEnvironmentVariableW(x, y, z)
#define ReadFile(a, b, c, d, e)
#define INVALID_HANDLE_VALUE
#define CreateFileMappingW(a, b, c, d, e, f)
#define CreateFileA(a, b, c, d, e, f, g)
static __inline const char * debugstr_an(const char *s, int n)
static __inline const char * wine_dbgstr_longlong(ULONGLONG ll)
#define ERROR_NO_MORE_ITEMS
#define ERROR_INVALID_HANDLE
#define WideCharToMultiByte
#define MultiByteToWideChar
#define ERROR_ACCESS_DENIED
static const WCHAR *const ext[]
BOOL WINAPI IsBadReadPtr(IN LPCVOID lp, IN UINT_PTR ucb)
BOOL NTAPI IsBadStringPtrA(IN LPCSTR lpsz, IN UINT_PTR ucchMax)
BOOL WINAPI DeleteFileW(IN LPCWSTR lpFileName)
BOOL WINAPI CreateDirectoryW(IN LPCWSTR lpPathName, IN LPSECURITY_ATTRIBUTES lpSecurityAttributes)
BOOL WINAPI GetDiskFreeSpaceExA(IN LPCSTR lpDirectoryName OPTIONAL, OUT PULARGE_INTEGER lpFreeBytesAvailableToCaller, OUT PULARGE_INTEGER lpTotalNumberOfBytes, OUT PULARGE_INTEGER lpTotalNumberOfFreeBytes)
BOOL WINAPI SetEndOfFile(HANDLE hFile)
BOOL WINAPI GetFileAttributesExW(LPCWSTR lpFileName, GET_FILEEX_INFO_LEVELS fInfoLevelId, LPVOID lpFileInformation)
DWORD WINAPI GetFileSize(HANDLE hFile, LPDWORD lpFileSizeHigh)
DWORD WINAPI GetShortPathNameW(IN LPCWSTR lpszLongPath, OUT LPWSTR lpszShortPath, IN DWORD cchBuffer)
BOOL WINAPI QueueUserWorkItem(IN LPTHREAD_START_ROUTINE Function, IN PVOID Context, IN ULONG Flags)
VOID WINAPI GetSystemTimeAsFileTime(OUT PFILETIME lpFileTime)
BOOL WINAPI DosDateTimeToFileTime(IN WORD wFatDate, IN WORD wFatTime, OUT LPFILETIME lpFileTime)
LONG WINAPI CompareFileTime(IN CONST FILETIME *lpFileTime1, IN CONST FILETIME *lpFileTime2)
BOOL WINAPI FileTimeToDosDateTime(IN CONST FILETIME *lpFileTime, OUT LPWORD lpFatDate, OUT LPWORD lpFatTime)
LPWSTR WINAPI CharLowerW(WCHAR *str)
_ACRTIMP int __cdecl memcmp(const void *, const void *, size_t)
_ACRTIMP int __cdecl wcsncmp(const wchar_t *, const wchar_t *, size_t)
_ACRTIMP void __cdecl qsort(void *, size_t, size_t, int(__cdecl *)(const void *, const void *))
_ACRTIMP int __cdecl rand(void)
_ACRTIMP size_t __cdecl strlen(const char *)
_ACRTIMP int __cdecl strcmp(const char *, const char *)
_ACRTIMP int __cdecl strncmp(const char *, const char *, size_t)
static char * strdup(const char *buf)
static wchar_t * wcsdup(const wchar_t *str)
BOOL WINAPI SHGetSpecialFolderPathW(HWND hwndOwner, LPWSTR szPath, int nFolder, BOOL bCreate)
BOOL WINAPI InternetCrackUrlW(const WCHAR *lpszUrl, DWORD dwUrlLength, DWORD dwFlags, URL_COMPONENTSW *lpUC)
void INTERNET_SetLastError(DWORD dwError)
BOOL WINAPI InternetCrackUrlA(const char *url, DWORD url_length, DWORD flags, URL_COMPONENTSA *ret_comp)
INTERNETAPI HANDLE WINAPI FindFirstUrlCacheEntryA(LPCSTR lpszUrlSearchPattern, LPINTERNET_CACHE_ENTRY_INFOA lpFirstCacheEntryInfo, LPDWORD lpdwFirstCacheEntryInfoBufferSize)
BOOL WINAPI GetUrlCacheEntryInfoA(LPCSTR lpszUrlName, LPINTERNET_CACHE_ENTRY_INFOA lpCacheEntryInfo, LPDWORD lpdwCacheEntryInfoBufferSize)
BOOL WINAPI GetUrlCacheGroupAttributeW(GROUPID gid, DWORD dwFlags, DWORD dwAttributes, LPINTERNET_CACHE_GROUP_INFOW lpGroupInfo, LPDWORD lpdwGroupInfo, LPVOID lpReserved)
static DWORD urlcache_hash_key(LPCSTR lpszKey)
static BOOL urlcache_entry_is_expired(const entry_url *pUrlEntry, FILETIME *pftLastModified)
#define PENDING_DELETE_CACHE_ENTRY
BOOL WINAPI FindCloseUrlCache(HANDLE hEnumHandle)
static DWORD urlcache_delete_file(const cache_container *container, urlcache_header *header, entry_url *url_entry)
static int urlcache_decode_url(const char *url, WCHAR *decoded_url, int decoded_len)
BOOL WINAPI FindNextUrlCacheEntryExW(HANDLE hEnumHandle, LPINTERNET_CACHE_ENTRY_INFOW lpFirstCacheEntryInfo, LPDWORD lpdwFirstCacheEntryInfoBufferSize, LPVOID lpReserved, LPDWORD pcbReserved2, LPVOID lpReserved3)
BOOL WINAPI SetUrlCacheEntryGroupA(LPCSTR lpszUrlName, DWORD dwFlags, GROUPID GroupId, LPBYTE pbGroupAttributes, DWORD cbGroupAttributes, LPVOID lpReserved)
#define HASHTABLE_NUM_ENTRIES
BOOL WINAPI DeleteUrlCacheEntryA(LPCSTR lpszUrlName)
static BOOL cache_container_is_valid(urlcache_header *header, DWORD file_size)
static BOOL cache_containers_add(const char *cache_prefix, LPCWSTR path, DWORD default_entry_type, LPWSTR mutex_name)
DWORD WINAPI DeleteIE3Cache(HWND hWnd, HINSTANCE hInst, LPSTR lpszCmdLine, int nCmdShow)
static BOOL urlcache_hash_entry_delete(struct hash_entry *pHashEntry)
static BOOL urlcache_get_entry_info(const char *url, void *entry_info, DWORD *size, DWORD flags, BOOL unicode)
static BOOL urlcache_enum_hash_tables(const urlcache_header *pHeader, DWORD *id, entry_hash_table **ppHashEntry)
static BOOL urlcache_encode_url_alloc(const WCHAR *url, char **encoded_url)
static void file_time_to_dos_date_time(const FILETIME *ft, WORD *fatdate, WORD *fattime)
BOOL WINAPI FreeUrlCacheSpaceA(LPCSTR lpszCachePath, DWORD dwSize, DWORD dwFilter)
static BOOL cache_containers_enum(char *search_pattern, DWORD index, cache_container **ret)
#define INSTALLED_CACHE_ENTRY
BOOL WINAPI UnlockUrlCacheEntryFileA(LPCSTR lpszUrlName, DWORD dwReserved)
DWORD WINAPI RegisterUrlCacheNotification(LPVOID a, DWORD b, DWORD c, DWORD d, DWORD e, DWORD f)
static void cache_container_close_index(cache_container *pContainer)
HANDLE WINAPI FindFirstUrlCacheContainerA(LPVOID p1, LPVOID p2, LPVOID p3, DWORD d1)
static BOOL urlcache_entry_get_file(const char *url, void *entry_info, DWORD *size, BOOL unicode)
#define URLCACHE_FIND_ENTRY_HANDLE_MAGIC
static DWORD urlcache_hash_entry_create(urlcache_header *pHeader, LPCSTR lpszUrl, DWORD dwOffsetEntry, DWORD dwFieldType)
BOOL WINAPI SetUrlCacheEntryInfoW(LPCWSTR lpszUrl, LPINTERNET_CACHE_ENTRY_INFOW lpCacheEntryInfo, DWORD dwFieldControl)
BOOL WINAPI GetUrlCacheGroupAttributeA(GROUPID gid, DWORD dwFlags, DWORD dwAttributes, LPINTERNET_CACHE_GROUP_INFOA lpGroupInfo, LPDWORD lpdwGroupInfo, LPVOID lpReserved)
HANDLE WINAPI FindFirstUrlCacheContainerW(LPVOID p1, LPVOID p2, LPVOID p3, DWORD d1)
static BOOL urlcache_entry_free(urlcache_header *header, entry_header *entry)
static BOOL urlcache_entry_create(const char *url, const char *ext, WCHAR *full_path)
static BOOL urlcache_enum_hash_table_entries(const urlcache_header *pHeader, const entry_hash_table *pHashEntry, DWORD *index, const struct hash_entry **ppHashEntry)
static int urlcache_encode_url(const WCHAR *url, char *encoded_url, int encoded_len)
static DWORD urlcache_create_hash_table(urlcache_header *header, entry_hash_table *hash_table_prev, entry_hash_table **hash_table)
BOOL WINAPI IsUrlCacheEntryExpiredA(LPCSTR url, DWORD dwFlags, FILETIME *pftLastModified)
static void cache_container_create_object_name(LPWSTR lpszPath, WCHAR replace)
#define HASHTABLE_BLOCKSIZE
BOOL WINAPI FindNextUrlCacheEntryExA(HANDLE hEnumHandle, LPINTERNET_CACHE_ENTRY_INFOA lpFirstCacheEntryInfo, LPDWORD lpdwFirstCacheEntryInfoBufferSize, LPVOID lpReserved, LPDWORD pcbReserved2, LPVOID lpReserved3)
BOOL WINAPI FindNextUrlCacheGroup(HANDLE hFind, GROUPID *lpGroupId, LPVOID lpReserved)
HANDLE WINAPI FindFirstUrlCacheEntryExA(LPCSTR lpszUrlSearchPattern, DWORD dwFlags, DWORD dwFilter, GROUPID GroupId, LPINTERNET_CACHE_ENTRY_INFOA lpFirstCacheEntryInfo, LPDWORD lpdwFirstCacheEntryInfoBufferSize, LPVOID lpReserved, LPDWORD pcbReserved2, LPVOID lpReserved3)
BOOL WINAPI CreateUrlCacheEntryA(LPCSTR lpszUrlName, DWORD dwExpectedFileSize, LPCSTR lpszFileExtension, LPSTR lpszFileName, DWORD dwReserved)
BOOL WINAPI CreateUrlCacheContainerA(DWORD d1, DWORD d2, DWORD d3, DWORD d4, DWORD d5, DWORD d6, DWORD d7, DWORD d8)
INTERNETAPI GROUPID WINAPI CreateUrlCacheGroup(DWORD dwFlags, LPVOID lpReserved)
static DWORD urlcache_set_entry_info(entry_url *url_entry, const INTERNET_CACHE_ENTRY_INFOA *entry_info, DWORD field_control)
BOOL WINAPI SetUrlCacheConfigInfoW(LPINTERNET_CACHE_CONFIG_INFOW lpCacheConfigInfo, DWORD dwFieldControl)
static void cache_container_delete_container(cache_container *pContainer)
static BOOL urlcache_create_file_pathW(const cache_container *pContainer, const urlcache_header *pHeader, LPCSTR szLocalFileName, BYTE Directory, LPWSTR wszPath, LPLONG lpBufferSize, BOOL trunc_name)
static DWORD cache_container_clean_index(cache_container *container, urlcache_header **file_view)
BOOL WINAPI GetUrlCacheEntryInfoW(LPCWSTR lpszUrl, LPINTERNET_CACHE_ENTRY_INFOW lpCacheEntryInfo, LPDWORD lpdwCacheEntryInfoBufferSize)
BOOL WINAPI GetUrlCacheEntryInfoExA(LPCSTR lpszUrl, LPINTERNET_CACHE_ENTRY_INFOA lpCacheEntryInfo, LPDWORD lpdwCacheEntryInfoBufSize, LPSTR lpszReserved, LPDWORD lpdwReserved, LPVOID lpReserved, DWORD dwFlags)
BOOL WINAPI SetUrlCacheGroupAttributeA(GROUPID gid, DWORD dwFlags, DWORD dwAttributes, LPINTERNET_CACHE_GROUP_INFOA lpGroupInfo, LPVOID lpReserved)
static BOOL urlcache_entry_commit(const char *url, const WCHAR *file_name, FILETIME expire_time, FILETIME modify_time, DWORD entry_type, BYTE *header_info, DWORD header_size, const char *file_ext, const char *original_url)
HANDLE WINAPI RetrieveUrlCacheEntryStreamW(LPCWSTR lpszUrlName, LPINTERNET_CACHE_ENTRY_INFOW lpCacheEntryInfo, LPDWORD lpdwCacheEntryInfoBufferSize, BOOL fRandomRead, DWORD dwReserved)
static DWORD urlcache_rate_entry(entry_url *url_entry, FILETIME *cur_time)
BOOL WINAPI FindNextUrlCacheContainerA(HANDLE handle, LPVOID p1, LPVOID p2)
static void urlcache_block_free(BYTE *allocation_table, DWORD block_number)
static DWORD WINAPI handle_full_cache_worker(void *param)
HANDLE WINAPI RetrieveUrlCacheEntryStreamA(LPCSTR lpszUrlName, LPINTERNET_CACHE_ENTRY_INFOA lpCacheEntryInfo, LPDWORD lpdwCacheEntryInfoBufferSize, BOOL fRandomRead, DWORD dwReserved)
static struct list UrlContainers
static DWORD urlcache_copy_entry(cache_container *container, const urlcache_header *header, INTERNET_CACHE_ENTRY_INFOA *entry_info, DWORD *info_size, const entry_url *url_entry, BOOL unicode)
BOOL WINAPI DeleteUrlCacheContainerW(DWORD d1, DWORD d2)
static entry_hash_table * urlcache_get_hash_table(const urlcache_header *pHeader, DWORD dwOffset)
static const char urlcache_ver[]
INTERNETAPI HANDLE WINAPI FindFirstUrlCacheEntryW(LPCWSTR lpszUrlSearchPattern, LPINTERNET_CACHE_ENTRY_INFOW lpFirstCacheEntryInfo, LPDWORD lpdwFirstCacheEntryInfoBufferSize)
static BOOL cache_container_unlock_index(cache_container *pContainer, urlcache_header *pHeader)
BOOL WINAPI SetUrlCacheConfigInfoA(LPINTERNET_CACHE_CONFIG_INFOA lpCacheConfigInfo, DWORD dwFieldControl)
#define CACHE_HEADER_DATA_ROOT_LEAK_OFFSET
BOOL WINAPI FindNextUrlCacheEntryA(HANDLE hEnumHandle, LPINTERNET_CACHE_ENTRY_INFOA lpNextCacheEntryInfo, LPDWORD lpdwNextCacheEntryInfoBufferSize)
static void cache_containers_free(void)
#define CACHE_CONTAINER_NO_SUBDIR
BOOL WINAPI FreeUrlCacheSpaceW(LPCWSTR cache_path, DWORD size, DWORD filter)
static const char urlcache_ver_prefix[]
BOOL WINAPI DeleteUrlCacheGroup(GROUPID GroupId, DWORD dwFlags, LPVOID lpReserved)
static BOOL urlcache_create_file_pathA(const cache_container *pContainer, const urlcache_header *pHeader, LPCSTR szLocalFileName, BYTE Directory, LPSTR szPath, LPLONG lpBufferSize)
static BOOL urlcache_next_entry(urlcache_header *header, DWORD *hash_table_off, DWORD *hash_table_entry, struct hash_entry **hash_entry, entry_header **entry)
static cache_container * find_container(DWORD flags)
static void urlcache_hash_entry_set_flags(struct hash_entry *pHashEntry, DWORD dwFlag)
static char * strdupWtoUTF8(const WCHAR *str)
BOOL WINAPI GetUrlCacheConfigInfoW(LPINTERNET_CACHE_CONFIG_INFOW info, LPDWORD size, DWORD flags)
BOOL bDefaultContainersAdded
#define HASHTABLE_FLAG_BITS
HANDLE WINAPI FindFirstUrlCacheEntryExW(LPCWSTR lpszUrlSearchPattern, DWORD dwFlags, DWORD dwFilter, GROUPID GroupId, LPINTERNET_CACHE_ENTRY_INFOW lpFirstCacheEntryInfo, LPDWORD lpdwFirstCacheEntryInfoBufferSize, LPVOID lpReserved, LPDWORD pcbReserved2, LPVOID lpReserved3)
BOOL WINAPI DeleteWpadCacheForNetworks(DWORD unk1)
BOOL WINAPI GetUrlCacheEntryInfoExW(LPCWSTR lpszUrl, LPINTERNET_CACHE_ENTRY_INFOW lpCacheEntryInfo, LPDWORD lpdwCacheEntryInfoBufSize, LPWSTR lpszReserved, LPDWORD lpdwReserved, LPVOID lpReserved, DWORD dwFlags)
BOOL WINAPI SetUrlCacheGroupAttributeW(GROUPID gid, DWORD dwFlags, DWORD dwAttributes, LPINTERNET_CACHE_GROUP_INFOW lpGroupInfo, LPVOID lpReserved)
BOOL WINAPI UnlockUrlCacheEntryFileW(LPCWSTR lpszUrlName, DWORD dwReserved)
BOOL WINAPI CreateUrlCacheEntryW(LPCWSTR lpszUrlName, DWORD dwExpectedFileSize, LPCWSTR lpszFileExtension, LPWSTR lpszFileName, DWORD dwReserved)
static DWORD urlcache_entry_alloc(urlcache_header *header, DWORD blocks_needed, entry_header **entry)
static BOOL cache_container_delete_dir(LPCWSTR lpszPath)
static urlcache_header * cache_container_lock_index(cache_container *pContainer)
HANDLE WINAPI FindFirstUrlCacheGroup(DWORD dwFlags, DWORD dwFilter, LPVOID lpSearchCondition, DWORD dwSearchCondition, GROUPID *lpGroupId, LPVOID lpReserved)
#define FILE_SIZE(blocks)
BOOL WINAPI FindNextUrlCacheContainerW(HANDLE handle, LPVOID p1, LPVOID p2)
static HANDLE free_cache_running
static void handle_full_cache(void)
BOOL WINAPI CommitUrlCacheEntryA(LPCSTR lpszUrlName, LPCSTR lpszLocalFileName, FILETIME ExpireTime, FILETIME LastModifiedTime, DWORD CacheEntryType, LPBYTE lpHeaderInfo, DWORD dwHeaderSize, LPCSTR lpszFileExtension, LPCSTR lpszOriginalUrl)
static BOOL urlcache_entry_delete(const cache_container *pContainer, urlcache_header *pHeader, struct hash_entry *pHashEntry)
#define ENTRY_START_OFFSET
BOOL WINAPI GetDiskInfoA(PCSTR path, PDWORD cluster_size, PDWORDLONG free, PDWORDLONG total)
BOOL WINAPI UnlockUrlCacheEntryStream(IN HANDLE hUrlCacheStream, IN DWORD dwReserved)
static DWORD cache_container_set_size(cache_container *container, HANDLE file, DWORD blocks_no)
static HANDLE cache_container_map_index(HANDLE file, const WCHAR *path, DWORD size, BOOL *validate)
static BOOL urlcache_find_next_entry(HANDLE hEnumHandle, LPINTERNET_CACHE_ENTRY_INFOA lpNextCacheEntryInfo, LPDWORD lpdwNextCacheEntryInfoBufferSize, BOOL unicode)
static void cache_containers_init(void)
BOOL WINAPI FindNextUrlCacheEntryW(HANDLE hEnumHandle, LPINTERNET_CACHE_ENTRY_INFOW lpNextCacheEntryInfo, LPDWORD lpdwNextCacheEntryInfoBufferSize)
static BYTE urlcache_block_is_free(BYTE *allocation_table, DWORD block_number)
BOOL WINAPI RetrieveUrlCacheEntryFileW(LPCWSTR lpszUrlName, LPINTERNET_CACHE_ENTRY_INFOW lpCacheEntryInfo, LPDWORD lpdwCacheEntryInfoBufferSize, DWORD dwReserved)
static BOOL urlcache_find_hash_entry(const urlcache_header *pHeader, LPCSTR lpszUrl, struct hash_entry **ppHashEntry)
BOOL WINAPI DeleteUrlCacheContainerA(DWORD d1, DWORD d2)
BOOL WINAPI SetUrlCacheEntryGroupW(LPCWSTR lpszUrlName, DWORD dwFlags, GROUPID GroupId, LPBYTE pbGroupAttributes, DWORD cbGroupAttributes, LPVOID lpReserved)
BOOL WINAPI CommitUrlCacheEntryW(LPCWSTR lpszUrlName, LPCWSTR lpszLocalFileName, FILETIME ExpireTime, FILETIME LastModifiedTime, DWORD CacheEntryType, LPWSTR lpHeaderInfo, DWORD dwHeaderSize, LPCWSTR lpszFileExtension, LPCWSTR lpszOriginalUrl)
BOOL WINAPI LoadUrlCacheContent(void)
static BOOL urlcache_hash_entry_is_locked(struct hash_entry *hash_entry, entry_url *url_entry)
static int __cdecl dword_cmp(const void *p1, const void *p2)
BOOL WINAPI SetUrlCacheEntryInfoA(LPCSTR lpszUrlName, LPINTERNET_CACHE_ENTRY_INFOA lpCacheEntryInfo, DWORD dwFieldControl)
BOOL WINAPI IsUrlCacheEntryExpiredW(LPCWSTR url, DWORD dwFlags, FILETIME *pftLastModified)
BOOL WINAPI IncrementUrlCacheHeaderData(DWORD index, LPDWORD data)
BOOL WINAPI GetUrlCacheConfigInfoA(LPINTERNET_CACHE_CONFIG_INFOA info, LPDWORD size, DWORD flags)
static DWORD cache_container_open_index(cache_container *container, DWORD blocks_no)
static void dos_date_time_to_file_time(WORD fatdate, WORD fattime, FILETIME *ft)
#define ALLOCATION_TABLE_SIZE
DWORD WINAPI RunOnceUrlCache(HWND hwnd, HINSTANCE hinst, LPSTR cmd, int cmdshow)
#define GET_INSTALLED_ENTRY
BOOL WINAPI CreateUrlCacheContainerW(DWORD d1, DWORD d2, DWORD d3, DWORD d4, DWORD d5, DWORD d6, DWORD d7, DWORD d8)
static BOOL urlcache_clean_leaked_entries(cache_container *container, urlcache_header *header)
static void urlcache_block_alloc(BYTE *allocation_table, DWORD block_number)
static HANDLE dll_unload_event
static DWORD cache_containers_find(const char *url, cache_container **ret)
BOOL WINAPI ReadUrlCacheEntryStream(IN HANDLE hUrlCacheStream, IN DWORD dwLocation, IN OUT LPVOID lpBuffer, IN OUT LPDWORD lpdwLen, IN DWORD dwReserved)
BOOL WINAPI DeleteUrlCacheEntryW(LPCWSTR lpszUrlName)
BOOL WINAPI RetrieveUrlCacheEntryFileA(LPCSTR lpszUrlName, LPINTERNET_CACHE_ENTRY_INFOA lpCacheEntryInfo, LPDWORD lpdwCacheEntryInfoBufferSize, DWORD dwReserved)
static const uint32_t k[]
static FRESULT validate(void *obj)
HANDLE NTAPI OpenFileMappingW(IN DWORD dwDesiredAccess, IN BOOL bInheritHandle, IN LPCWSTR lpName)
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
GLdouble GLdouble GLdouble r
GLboolean GLboolean GLboolean b
GLenum GLenum GLenum GLenum mapping
GLboolean GLboolean GLboolean GLboolean a
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint GLint GLint j
FxContextHeader * pHeader
#define WC_NO_BEST_FIT_CHARS
REFIID LPVOID DWORD_PTR dw
static DWORD block_size(DWORD block)
static const SecPkgInfoW infoW
LPWSTR WINAPI lstrcatW(LPWSTR lpString1, LPCWSTR lpString2)
#define memcpy(s1, s2, n)
#define FILE_FLAG_RANDOM_ACCESS
#define ERROR_FILE_NOT_FOUND
PSDBQUERYRESULT_VISTA PVOID DWORD * dwSize
_In_ HANDLE _In_ DWORD _In_ DWORD _Inout_opt_ LPOVERLAPPED _In_opt_ LPTRANSMIT_FILE_BUFFERS _In_ DWORD dwReserved
_In_ BOOLEAN _In_ USHORT Directory
_In_ LPWSTR _In_ DWORD _In_ DWORD _In_ DWORD dwFlags
_In_ DWORD _In_ DWORD dwOffset
int WINAPIV wsprintfW(_Out_ LPWSTR, _In_ _Printf_format_string_ LPCWSTR,...)
static unsigned int file_size
INT replace(TCHAR source[MAX_PATH], TCHAR dest[MAX_PATH], DWORD dwFlags, BOOL *doMore)
#define LIST_FOR_EACH_ENTRY(elem, list, type, field)
#define FOF_NOCONFIRMATION
int WINAPI SHFileOperationW(LPSHFILEOPSTRUCTW lpFileOp)
#define CSIDL_INTERNET_CACHE
FILETIME LastModifiedTime
BOOL fAnyOperationsAborted
struct _ULARGE_INTEGER::@5176 u
struct hash_entry hash_table[HASHTABLE_SIZE]
FILETIME modification_time
char * url_search_pattern
DWORD WINAPI WaitForSingleObject(IN HANDLE hHandle, IN DWORD dwMilliseconds)
VOID WINAPI DECLSPEC_HOTPATCH Sleep(IN DWORD dwMilliseconds)
HANDLE WINAPI DECLSPEC_HOTPATCH CreateMutexW(IN LPSECURITY_ATTRIBUTES lpMutexAttributes OPTIONAL, IN BOOL bInitialOwner, IN LPCWSTR lpName OPTIONAL)
BOOL WINAPI DECLSPEC_HOTPATCH ReleaseMutex(IN HANDLE hMutex)
HANDLE WINAPI DECLSPEC_HOTPATCH CreateEventW(IN LPSECURITY_ATTRIBUTES lpEventAttributes OPTIONAL, IN BOOL bManualReset, IN BOOL bInitialState, IN LPCWSTR lpName OPTIONAL)
BOOL WINAPI DECLSPEC_HOTPATCH SetEvent(IN HANDLE hEvent)
HANDLE WINAPI DECLSPEC_HOTPATCH CreateSemaphoreW(IN LPSECURITY_ATTRIBUTES lpSemaphoreAttributes OPTIONAL, IN LONG lInitialCount, IN LONG lMaximumCount, IN LPCWSTR lpName OPTIONAL)
BOOL WINAPI DECLSPEC_HOTPATCH ReleaseSemaphore(IN HANDLE hSemaphore, IN LONG lReleaseCount, IN LPLONG lpPreviousCount)
DWORD WINAPI GetLastError(void)
#define INVALID_FILE_SIZE
#define ERROR_SHARING_VIOLATION
#define ERROR_HANDLE_DISK_FULL
#define ERROR_ENVVAR_NOT_FOUND
#define ERROR_INVALID_DATA
#define INTERNET_SCHEME_HTTP
#define INTERNET_SCHEME_HTTPS
#define CACHE_ENTRY_HEADERINFO_FC
#define COOKIE_CACHE_ENTRY
#define ERROR_INTERNET_INVALID_URL
#define URLHISTORY_CACHE_ENTRY
#define INTERNET_MAX_URL_LENGTH
#define CACHE_ENTRY_EXPTIME_FC
#define CACHE_ENTRY_EXEMPT_DELTA_FC
#define CACHE_ENTRY_ATTRIBUTE_FC
#define NORMAL_CACHE_ENTRY
#define STICKY_CACHE_ENTRY
#define CACHE_ENTRY_HITRATE_FC
@ INTERNET_SCHEME_UNKNOWN
#define CACHE_ENTRY_ACCTIME_FC
#define CACHE_ENTRY_SYNCTIME_FC
#define CACHE_ENTRY_MODTIME_FC
#define CACHE_CONFIG_CONTENT_PATHS_FC
#define CACHE_CONFIG_HISTORY_PATHS_FC
#define CACHE_CONFIG_COOKIES_PATHS_FC
_In_ DWORD _In_ int _In_ int _In_opt_ LPNLSVERSIONINFO _In_opt_ LPVOID lpReserved
#define HKEY_CURRENT_USER
static unsigned int block