Pelles C forum

Pelles C => Bug reports => Topic started by: alderman on October 31, 2019, 08:13:08 PM

Title: DeleteUrlCacheEntry when I updated to 9.0 it is no longer found
Post by: alderman on October 31, 2019, 08:13:08 PM
I sometimes use this: DeleteUrlCacheEntry
But when I updated to 9.0 it is no longer found.

DeleteUrlCacheEntry and DeleteUrlCacheEntryA are the same feature according to Microsoft. I switched to DeleteUrlCacheEntryA and then it works again.

https://docs.microsoft.com/en-us/windows/win32/api/wininet/nf-wininet-deleteurlcacheentrya

These are the same:
BOOLAPI DeleteUrlCacheEntry (
   LPCSTR  lpszUrlName
);
and
BOOLAPI DeleteUrlCacheEntryA (
   LPCSTR  lpszUrlName
);

But this one is not the same:
BOOLAPI DeleteUrlCacheEntryW (
    LPCWSTR  lpszUrlName
);

So it should say in wininet.h:
#define DeleteUrlCacheEntry DeleteUrlCacheEntryA



But when I go into the wininet.h file that comes with Pelles C, I see this:
#define DeleteUrlCacheEntry DeleteUrlCacheEntryW


Is it something wrong or am I wrong and why did it work in earlier version but not in 9.0?
Title: Re: DeleteUrlCacheEntry when I updated to 9.0 it is no longer found
Post by: TimoVJL on October 31, 2019, 11:32:33 PM
So that function name is missing from WinInet.lib (x86)
Microsoft defines:
Code: [Select]
BOOLAPI DeleteUrlCacheEntryA(
    _In_ LPCSTR lpszUrlName
    );

BOOLAPI DeleteUrlCacheEntryW(
    _In_ LPCWSTR lpszUrlName
    );

#ifdef UNICODE
#define DeleteUrlCacheEntry  DeleteUrlCacheEntryW
#else
#ifdef _WINX32_
#define DeleteUrlCacheEntry  DeleteUrlCacheEntryA
#else
BOOLAPI DeleteUrlCacheEntry(
    _In_ LPCSTR lpszUrlName
    );
#endif // _WINX32_
EDIT:  so wininet.h needs fix
Title: Re: DeleteUrlCacheEntry when I updated to 9.0 it is no longer found
Post by: alderman on November 01, 2019, 01:16:32 AM
So that function name is missing from WinInet.lib (x86)
Microsoft defines:
Code: [Select]
BOOLAPI DeleteUrlCacheEntryA(
    _In_ LPCSTR lpszUrlName
    );

BOOLAPI DeleteUrlCacheEntryW(
    _In_ LPCWSTR lpszUrlName
    );

#ifdef UNICODE
#define DeleteUrlCacheEntry  DeleteUrlCacheEntryW
#else
#ifdef _WINX32_
#define DeleteUrlCacheEntry  DeleteUrlCacheEntryA
#else
BOOLAPI DeleteUrlCacheEntry(
    _In_ LPCSTR lpszUrlName
    );
#endif // _WINX32_


The compiler said nothing about it in the previous Pelles C version. It was only with v9.0 that I got into trouble.