ReactOS  0.4.14-dev-552-g2fad488
urlmon_main.c File Reference
#include <stdarg.h>
#include "urlmon_main.h"
#include "winreg.h"
#include "shlwapi.h"
#include "advpub.h"
#include "initguid.h"
#include "wine/debug.h"
#include "urlmon.h"
Include dependency graph for urlmon_main.c:

Go to the source code of this file.

Classes

class  ClassFactory
 
struct  object_creation_info
 

Macros

#define NONAMELESSUNION
 
#define NO_SHLWAPI_REG
 
#define X(x)   case x: return #x
 

Functions

 WINE_DEFAULT_DEBUG_CHANNEL (urlmon)
 
 DEFINE_GUID (CLSID_CUri, 0xDF2FCE13, 0x25EC, 0x45BB, 0x9D, 0x4C, 0xCE, 0xCD, 0x47, 0xC2, 0x43, 0x0C)
 
static void init_session (void)
 
tls_data_tget_tls_data (void)
 
static void free_tls_list (void)
 
static void detach_thread (void)
 
static void process_detach (void)
 
BOOL WINAPI DllMain (HINSTANCE hinstDLL, DWORD fdwReason, LPVOID fImpLoad)
 
const chardebugstr_bindstatus (ULONG status)
 
HRESULT WINAPI DllInstall (BOOL bInstall, LPCWSTR cmdline)
 
HRESULT WINAPI DllCanUnloadNow (void)
 
static ClassFactoryimpl_from_IClassFactory (IClassFactory *iface)
 
static HRESULT WINAPI CF_QueryInterface (IClassFactory *iface, REFIID riid, LPVOID *ppv)
 
static ULONG WINAPI CF_AddRef (IClassFactory *iface)
 
static ULONG WINAPI CF_Release (IClassFactory *iface)
 
static HRESULT WINAPI CF_CreateInstance (IClassFactory *iface, IUnknown *outer, REFIID riid, void **ppv)
 
static HRESULT WINAPI CF_LockServer (LPCLASSFACTORY iface, BOOL dolock)
 
HRESULT WINAPI DllGetClassObject (REFCLSID rclsid, REFIID riid, LPVOID *ppv)
 
static HRESULT register_inf (BOOL doregister)
 
HRESULT WINAPI DllRegisterServer (void)
 
HRESULT WINAPI DllUnregisterServer (void)
 
HRESULT WINAPI DllRegisterServerEx (void)
 
HRESULT WINAPI IsValidURL (LPBC pBC, LPCWSTR szURL, DWORD dwReserved)
 
HRESULT WINAPI FaultInIEFeature (HWND hwnd, uCLSSPEC *pClassSpec, QUERYCONTEXT *pQuery, DWORD flags)
 
HRESULT WINAPI CoGetClassObjectFromURL (REFCLSID rclsid, LPCWSTR szCodeURL, DWORD dwFileVersionMS, DWORD dwFileVersionLS, LPCWSTR szContentType, LPBINDCTX pBindCtx, DWORD dwClsContext, LPVOID pvReserved, REFIID riid, LPVOID *ppv)
 
void WINAPI ReleaseBindInfo (BINDINFO *pbindinfo)
 
HRESULT WINAPI CopyStgMedium (const STGMEDIUM *src, STGMEDIUM *dst)
 
HRESULT WINAPI CopyBindInfo (const BINDINFO *pcbiSrc, BINDINFO *pcbiDest)
 
HRESULT WINAPI GetClassFileOrMime (LPBC pBC, LPCWSTR pszFilename, LPVOID pBuffer, DWORD cbBuffer, LPCWSTR pszMimeType, DWORD dwReserved, CLSID *pclsid)
 
HRESULT WINAPI Extract (void *dest, LPCSTR szCabName)
 
BOOL WINAPI IsLoggingEnabledA (LPCSTR url)
 
BOOL WINAPI IsLoggingEnabledW (LPCWSTR url)
 
BOOL WINAPI IsProtectedModeURL (const WCHAR *url)
 
int WINAPI LogSqmBits (DWORD unk1, DWORD unk2)
 
void WINAPI LogSqmUXCommandOffsetInternal (DWORD unk1, DWORD unk2, DWORD unk3, DWORD unk4)
 
int WINAPI MapUriToBrowserEmulationState (DWORD unk1, DWORD unk2, DWORD unk3)
 
int WINAPI MapBrowserEmulationModeToUserAgent (DWORD unk1, DWORD unk2)
 
HRESULT WINAPI CoInternetGetBrowserProfile (DWORD unk)
 
void WINAPI FlushUrlmonZonesCache (void)
 
HRESULT WINAPI RegisterMediaTypes (UINT types, LPCSTR *szTypes, CLIPFORMAT *cfTypes)
 
BOOL WINAPI ShouldShowIntranetWarningSecband (DWORD unk)
 
HRESULT WINAPI GetIUriPriv (IUri *uri, void **p)
 

Variables

LONG URLMON_refCount = 0
 
HINSTANCE urlmon_instance
 
static HMODULE hCabinet = NULL
 
static DWORD urlmon_tls = TLS_OUT_OF_INDEXES
 
static struct list tls_list = LIST_INIT(tls_list)
 
static CRITICAL_SECTION tls_cs = { &tls_cs_dbg, -1, 0, 0, 0, 0 }
 
static CRITICAL_SECTION_DEBUG tls_cs_dbg
 
static const IClassFactoryVtbl ClassFactoryVtbl
 
static ClassFactory FileProtocolCF
 
static ClassFactory FtpProtocolCF
 
static ClassFactory GopherProtocolCF
 
static ClassFactory HttpProtocolCF
 
static ClassFactory HttpSProtocolCF
 
static ClassFactory MkProtocolCF
 
static ClassFactory SecurityManagerCF
 
static ClassFactory ZoneManagerCF
 
static ClassFactory StdURLMonikerCF
 
static ClassFactory MimeFilterCF
 
static ClassFactory CUriCF
 
static const WCHAR wszFile [] = {'f','i','l','e',0}
 
static const WCHAR wszFtp [] = {'f','t','p',0}
 
static const WCHAR wszGopher [] = {'g','o','p','h','e','r',0}
 
static const WCHAR wszHttp [] = {'h','t','t','p',0}
 
static const WCHAR wszHttps [] = {'h','t','t','p','s',0}
 
static const WCHAR wszMk [] = {'m','k',0}
 
static const struct object_creation_info object_creation []
 

Macro Definition Documentation

◆ NO_SHLWAPI_REG

#define NO_SHLWAPI_REG

Definition at line 29 of file urlmon_main.c.

◆ NONAMELESSUNION

#define NONAMELESSUNION

Definition at line 23 of file urlmon_main.c.

◆ X

#define X (   x)    case x: return #x

Function Documentation

◆ CF_AddRef()

static ULONG WINAPI CF_AddRef ( IClassFactory iface)
static

Definition at line 293 of file urlmon_main.c.

294 {
296  return 2;
297 }
static void URLMON_LockModule(void)
Definition: urlmon_main.h:68

◆ CF_CreateInstance()

static HRESULT WINAPI CF_CreateInstance ( IClassFactory iface,
IUnknown outer,
REFIID  riid,
void **  ppv 
)
static

Definition at line 306 of file urlmon_main.c.

308 {
310  IUnknown *unk;
311  HRESULT hres;
312 
313  TRACE("(%p)->(%p %s %p)\n", This, outer, debugstr_guid(riid), ppv);
314 
315  if(outer && !IsEqualGUID(riid, &IID_IUnknown)) {
316  *ppv = NULL;
317  return CLASS_E_NOAGGREGATION;
318  }
319 
320  hres = This->pfnCreateInstance(outer, (void**)&unk);
321  if(FAILED(hres)) {
322  *ppv = NULL;
323  return hres;
324  }
325 
326  if(!IsEqualGUID(riid, &IID_IUnknown)) {
327  hres = IUnknown_QueryInterface(unk, riid, ppv);
328  IUnknown_Release(unk);
329  }else {
330  *ppv = unk;
331  }
332  return hres;
333 }
REFIID riid
Definition: precomp.h:44
REFIID LPVOID * ppv
Definition: atlbase.h:39
smooth NULL
Definition: ftsmooth.c:416
#define debugstr_guid
Definition: kernel32.h:35
#define TRACE(s)
Definition: solgame.cpp:4
HRESULT hres
Definition: protocol.c:465
LONG HRESULT
Definition: typedefs.h:77
const GUID IID_IUnknown
#define CLASS_E_NOAGGREGATION
Definition: winerror.h:2662
static ClassFactory * impl_from_IClassFactory(IClassFactory *iface)
Definition: urlmon_main.c:267
BOOL WINAPI IsEqualGUID(REFGUID rguid1, REFGUID rguid2)
Definition: compobj.c:4112

Referenced by ClassFactory_CreateInstance(), and test_default_handler_run().

◆ CF_LockServer()

static HRESULT WINAPI CF_LockServer ( LPCLASSFACTORY  iface,
BOOL  dolock 
)
static

Definition at line 335 of file urlmon_main.c.

336 {
337  TRACE("(%d)\n", dolock);
338 
339  if (dolock)
341  else
343 
344  return S_OK;
345 }
static void URLMON_UnlockModule(void)
Definition: urlmon_main.h:69
#define TRACE(s)
Definition: solgame.cpp:4
#define S_OK
Definition: intsafe.h:59
static void URLMON_LockModule(void)
Definition: urlmon_main.h:68

◆ CF_QueryInterface()

static HRESULT WINAPI CF_QueryInterface ( IClassFactory iface,
REFIID  riid,
LPVOID ppv 
)
static

Definition at line 272 of file urlmon_main.c.

273 {
274  *ppv = NULL;
275 
276  if(IsEqualGUID(riid, &IID_IUnknown)) {
277  TRACE("(%p)->(IID_IUnknown %p)\n", iface, ppv);
278  *ppv = iface;
279  }else if(IsEqualGUID(riid, &IID_IClassFactory)) {
280  TRACE("(%p)->(IID_IClassFactory %p)\n", iface, ppv);
281  *ppv = iface;
282  }
283 
284  if(*ppv) {
285  IUnknown_AddRef((IUnknown*)*ppv);
286  return S_OK;
287  }
288 
289  WARN("(%p)->(%s,%p),not found\n", iface, debugstr_guid(riid), ppv);
290  return E_NOINTERFACE;
291 }
#define E_NOINTERFACE
Definition: winerror.h:2364
REFIID riid
Definition: precomp.h:44
#define WARN(fmt,...)
Definition: debug.h:111
REFIID LPVOID * ppv
Definition: atlbase.h:39
smooth NULL
Definition: ftsmooth.c:416
#define debugstr_guid
Definition: kernel32.h:35
#define TRACE(s)
Definition: solgame.cpp:4
const GUID IID_IUnknown
#define S_OK
Definition: intsafe.h:59
BOOL WINAPI IsEqualGUID(REFGUID rguid1, REFGUID rguid2)
Definition: compobj.c:4112
const GUID IID_IClassFactory

◆ CF_Release()

static ULONG WINAPI CF_Release ( IClassFactory iface)
static

Definition at line 299 of file urlmon_main.c.

300 {
302  return 1;
303 }
static void URLMON_UnlockModule(void)
Definition: urlmon_main.h:69

◆ CoGetClassObjectFromURL()

HRESULT WINAPI CoGetClassObjectFromURL ( REFCLSID  rclsid,
LPCWSTR  szCodeURL,
DWORD  dwFileVersionMS,
DWORD  dwFileVersionLS,
LPCWSTR  szContentType,
LPBINDCTX  pBindCtx,
DWORD  dwClsContext,
LPVOID  pvReserved,
REFIID  riid,
LPVOID ppv 
)

Definition at line 550 of file urlmon_main.c.

554 {
555  FIXME("(%s %s %d %d %s %p %d %p %s %p) Stub!\n", debugstr_guid(rclsid), debugstr_w(szCodeURL),
556  dwFileVersionMS, dwFileVersionLS, debugstr_w(szContentType), pBindCtx, dwClsContext, pvReserved,
558  return E_NOINTERFACE;
559 }
#define E_NOINTERFACE
Definition: winerror.h:2364
REFIID riid
Definition: precomp.h:44
REFIID LPVOID * ppv
Definition: atlbase.h:39
#define debugstr_w
Definition: kernel32.h:32
#define FIXME(fmt,...)
Definition: debug.h:110
#define debugstr_guid
Definition: kernel32.h:35
static LPCSTR DWORD void * pvReserved
Definition: str.c:196

◆ CoInternetGetBrowserProfile()

HRESULT WINAPI CoInternetGetBrowserProfile ( DWORD  unk)

Definition at line 817 of file urlmon_main.c.

818 {
819  FIXME("%x: stub\n", unk);
820  return E_NOTIMPL;
821 }
#define FIXME(fmt,...)
Definition: debug.h:110
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ CopyBindInfo()

HRESULT WINAPI CopyBindInfo ( const BINDINFO *  pcbiSrc,
BINDINFO *  pcbiDest 
)

Definition at line 654 of file urlmon_main.c.

655 {
656  DWORD size;
657  HRESULT hres;
658 
659  TRACE("(%p %p)\n", pcbiSrc, pcbiDest);
660 
661  if(!pcbiSrc || !pcbiDest)
662  return E_POINTER;
663  if(!pcbiSrc->cbSize || !pcbiDest->cbSize)
664  return E_INVALIDARG;
665 
666  size = pcbiDest->cbSize;
667  if(size > pcbiSrc->cbSize) {
668  memcpy(pcbiDest, pcbiSrc, pcbiSrc->cbSize);
669  memset((char*)pcbiDest+pcbiSrc->cbSize, 0, size-pcbiSrc->cbSize);
670  } else {
671  memcpy(pcbiDest, pcbiSrc, size);
672  }
673  pcbiDest->cbSize = size;
674 
675  size = FIELD_OFFSET(BINDINFO, szExtraInfo)+sizeof(void*);
676  if(pcbiSrc->cbSize>=size && pcbiDest->cbSize>=size && pcbiSrc->szExtraInfo) {
677  size = (lstrlenW(pcbiSrc->szExtraInfo)+1)*sizeof(WCHAR);
678  pcbiDest->szExtraInfo = CoTaskMemAlloc(size);
679  if(!pcbiDest->szExtraInfo)
680  return E_OUTOFMEMORY;
681  memcpy(pcbiDest->szExtraInfo, pcbiSrc->szExtraInfo, size);
682  }
683 
684  size = FIELD_OFFSET(BINDINFO, stgmedData)+sizeof(STGMEDIUM);
685  if(pcbiSrc->cbSize>=size && pcbiDest->cbSize>=size) {
686  hres = CopyStgMedium(&pcbiSrc->stgmedData, &pcbiDest->stgmedData);
687  if(FAILED(hres)) {
688  CoTaskMemFree(pcbiDest->szExtraInfo);
689  return hres;
690  }
691  }
692 
693  size = FIELD_OFFSET(BINDINFO, szCustomVerb)+sizeof(void*);
694  if(pcbiSrc->cbSize>=size && pcbiDest->cbSize>=size && pcbiSrc->szCustomVerb) {
695  size = (lstrlenW(pcbiSrc->szCustomVerb)+1)*sizeof(WCHAR);
696  pcbiDest->szCustomVerb = CoTaskMemAlloc(size);
697  if(!pcbiDest->szCustomVerb) {
698  CoTaskMemFree(pcbiDest->szExtraInfo);
699  ReleaseStgMedium(&pcbiDest->stgmedData);
700  return E_OUTOFMEMORY;
701  }
702  memcpy(pcbiDest->szCustomVerb, pcbiSrc->szCustomVerb, size);
703  }
704 
705  size = FIELD_OFFSET(BINDINFO, securityAttributes)+sizeof(SECURITY_ATTRIBUTES);
706  if(pcbiDest->cbSize >= size)
707  memset(&pcbiDest->securityAttributes, 0, sizeof(SECURITY_ATTRIBUTES));
708 
709  if(pcbiSrc->pUnk)
710  IUnknown_AddRef(pcbiDest->pUnk);
711 
712  return S_OK;
713 }
VOID WINAPI CoTaskMemFree(LPVOID ptr)
Definition: ifs.c:420
void WINAPI ReleaseStgMedium(STGMEDIUM *pmedium)
Definition: ole2.c:2033
#define lstrlenW
Definition: compat.h:415
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
#define E_INVALIDARG
Definition: ddrawi.h:101
#define TRACE(s)
Definition: solgame.cpp:4
GLsizeiptr size
Definition: glext.h:5919
HRESULT hres
Definition: protocol.c:465
HRESULT WINAPI CopyStgMedium(const STGMEDIUM *src, STGMEDIUM *dst)
Definition: urlmon_main.c:597
__wchar_t WCHAR
Definition: xmlstorage.h:180
LONG HRESULT
Definition: typedefs.h:77
unsigned long DWORD
Definition: ntddk_ex.h:95
#define memcpy(s1, s2, n)
Definition: mkisofs.h:878
#define S_OK
Definition: intsafe.h:59
#define FIELD_OFFSET(t, f)
Definition: typedefs.h:254
#define E_POINTER
Definition: winerror.h:2365
#define memset(x, y, z)
Definition: compat.h:39
LPVOID WINAPI CoTaskMemAlloc(SIZE_T size)
Definition: ifs.c:404
struct _SECURITY_ATTRIBUTES SECURITY_ATTRIBUTES

Referenced by InternetBindInfo_GetBindInfo().

◆ CopyStgMedium()

HRESULT WINAPI CopyStgMedium ( const STGMEDIUM *  src,
STGMEDIUM *  dst 
)

Definition at line 597 of file urlmon_main.c.

598 {
599  TRACE("(%p %p)\n", src, dst);
600 
601  if(!src || !dst)
602  return E_POINTER;
603 
604  *dst = *src;
605 
606  switch(dst->tymed) {
607  case TYMED_NULL:
608  break;
609  case TYMED_FILE:
610  if(src->u.lpszFileName && !src->pUnkForRelease) {
611  DWORD size = (lstrlenW(src->u.lpszFileName)+1)*sizeof(WCHAR);
612  dst->u.lpszFileName = CoTaskMemAlloc(size);
613  if(!dst->u.lpszFileName)
614  return E_OUTOFMEMORY;
615  memcpy(dst->u.lpszFileName, src->u.lpszFileName, size);
616  }
617  break;
618  case TYMED_ISTREAM:
619  if(dst->u.pstm)
620  IStream_AddRef(dst->u.pstm);
621  break;
622  case TYMED_ISTORAGE:
623  if(dst->u.pstg)
624  IStorage_AddRef(dst->u.pstg);
625  break;
626  case TYMED_HGLOBAL:
627  if(dst->u.hGlobal) {
628  SIZE_T size = GlobalSize(src->u.hGlobal);
629  char *src_ptr, *dst_ptr;
630 
631  dst->u.hGlobal = GlobalAlloc(GMEM_FIXED, size);
632  if(!dst->u.hGlobal)
633  return E_OUTOFMEMORY;
634  dst_ptr = GlobalLock(dst->u.hGlobal);
635  src_ptr = GlobalLock(src->u.hGlobal);
636  memcpy(dst_ptr, src_ptr, size);
637  GlobalUnlock(src_ptr);
638  GlobalUnlock(dst_ptr);
639  }
640  break;
641  default:
642  FIXME("Unimplemented tymed %d\n", src->tymed);
643  }
644 
645  if(dst->pUnkForRelease)
646  IUnknown_AddRef(dst->pUnkForRelease);
647 
648  return S_OK;
649 }
HGLOBAL NTAPI GlobalAlloc(UINT uFlags, SIZE_T dwBytes)
Definition: heapmem.c:368
#define lstrlenW
Definition: compat.h:415
SIZE_T NTAPI GlobalSize(HGLOBAL hMem)
Definition: heapmem.c:1090
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
#define FIXME(fmt,...)
Definition: debug.h:110
#define TRACE(s)
Definition: solgame.cpp:4
GLsizeiptr size
Definition: glext.h:5919
__wchar_t WCHAR
Definition: xmlstorage.h:180
unsigned long DWORD
Definition: ntddk_ex.h:95
LPVOID NTAPI GlobalLock(HGLOBAL hMem)
Definition: heapmem.c:755
#define GMEM_FIXED
Definition: winbase.h:290
#define memcpy(s1, s2, n)
Definition: mkisofs.h:878
GLenum src
Definition: glext.h:6340
ULONG_PTR SIZE_T
Definition: typedefs.h:78
#define S_OK
Definition: intsafe.h:59
GLenum GLenum dst
Definition: glext.h:6340
BOOL NTAPI GlobalUnlock(HGLOBAL hMem)
Definition: heapmem.c:1190
#define E_POINTER
Definition: winerror.h:2365
LPVOID WINAPI CoTaskMemAlloc(SIZE_T size)
Definition: ifs.c:404

Referenced by CopyBindInfo().

◆ debugstr_bindstatus()

const char* debugstr_bindstatus ( ULONG  status)

Definition at line 175 of file urlmon_main.c.

176 {
177  switch(status) {
178 #define X(x) case x: return #x
179  X(BINDSTATUS_FINDINGRESOURCE);
180  X(BINDSTATUS_CONNECTING);
181  X(BINDSTATUS_REDIRECTING);
182  X(BINDSTATUS_BEGINDOWNLOADDATA);
183  X(BINDSTATUS_DOWNLOADINGDATA);
184  X(BINDSTATUS_ENDDOWNLOADDATA);
185  X(BINDSTATUS_BEGINDOWNLOADCOMPONENTS);
186  X(BINDSTATUS_INSTALLINGCOMPONENTS);
187  X(BINDSTATUS_ENDDOWNLOADCOMPONENTS);
188  X(BINDSTATUS_USINGCACHEDCOPY);
189  X(BINDSTATUS_SENDINGREQUEST);
190  X(BINDSTATUS_CLASSIDAVAILABLE);
191  X(BINDSTATUS_MIMETYPEAVAILABLE);
192  X(BINDSTATUS_CACHEFILENAMEAVAILABLE);
193  X(BINDSTATUS_BEGINSYNCOPERATION);
194  X(BINDSTATUS_ENDSYNCOPERATION);
195  X(BINDSTATUS_BEGINUPLOADDATA);
196  X(BINDSTATUS_UPLOADINGDATA);
197  X(BINDSTATUS_ENDUPLOADINGDATA);
198  X(BINDSTATUS_PROTOCOLCLASSID);
199  X(BINDSTATUS_ENCODING);
200  X(BINDSTATUS_VERIFIEDMIMETYPEAVAILABLE);
201  X(BINDSTATUS_CLASSINSTALLLOCATION);
202  X(BINDSTATUS_DECODING);
203  X(BINDSTATUS_LOADINGMIMEHANDLER);
204  X(BINDSTATUS_CONTENTDISPOSITIONATTACH);
205  X(BINDSTATUS_FILTERREPORTMIMETYPE);
206  X(BINDSTATUS_CLSIDCANINSTANTIATE);
207  X(BINDSTATUS_IUNKNOWNAVAILABLE);
208  X(BINDSTATUS_DIRECTBIND);
209  X(BINDSTATUS_RAWMIMETYPE);
210  X(BINDSTATUS_PROXYDETECTING);
211  X(BINDSTATUS_ACCEPTRANGES);
212  X(BINDSTATUS_COOKIE_SENT);
213  X(BINDSTATUS_COMPACT_POLICY_RECEIVED);
214  X(BINDSTATUS_COOKIE_SUPPRESSED);
215  X(BINDSTATUS_COOKIE_STATE_UNKNOWN);
216  X(BINDSTATUS_COOKIE_STATE_ACCEPT);
217  X(BINDSTATUS_COOKIE_STATE_REJECT);
218  X(BINDSTATUS_COOKIE_STATE_PROMPT);
219  X(BINDSTATUS_COOKIE_STATE_LEASH);
220  X(BINDSTATUS_COOKIE_STATE_DOWNGRADE);
221  X(BINDSTATUS_POLICY_HREF);
222  X(BINDSTATUS_P3P_HEADER);
223  X(BINDSTATUS_SESSION_COOKIE_RECEIVED);
224  X(BINDSTATUS_PERSISTENT_COOKIE_RECEIVED);
225  X(BINDSTATUS_SESSION_COOKIES_ALLOWED);
226  X(BINDSTATUS_CACHECONTROL);
227  X(BINDSTATUS_CONTENTDISPOSITIONFILENAME);
228  X(BINDSTATUS_MIMETEXTPLAINMISMATCH);
229  X(BINDSTATUS_PUBLISHERAVAILABLE);
230  X(BINDSTATUS_DISPLAYNAMEAVAILABLE);
231 #undef X
232  default:
233  return wine_dbg_sprintf("(invalid status %u)", status);
234  }
235 }
const char * wine_dbg_sprintf(const char *format,...)
Definition: compat.c:271
#define X(x)
Definition: ps.c:97

Referenced by BindStatusCallback_OnProgress(), InternetProtocolSink_ReportProgress(), and ProtocolSinkHandler_ReportProgress().

◆ DEFINE_GUID()

DEFINE_GUID ( CLSID_CUri  ,
0xDF2FCE13  ,
0x25EC  ,
0x45BB  ,
0x9D  ,
0x4C  ,
0xCE  ,
0xCD  ,
0x47  ,
0xC2  ,
0x43  ,
0x0C   
)

◆ detach_thread()

static void detach_thread ( void  )
static

Definition at line 108 of file urlmon_main.c.

109 {
110  tls_data_t *data;
111 
113  return;
114 
116  if(!data)
117  return;
118 
120  list_remove(&data->entry);
122 
123  if(data->notif_hwnd) {
124  WARN("notif_hwnd not destroyed\n");
125  DestroyWindow(data->notif_hwnd);
126  }
127 
128  heap_free(data);
129 }
#define WARN(fmt,...)
Definition: debug.h:111
static CRITICAL_SECTION tls_cs
Definition: urlmon_main.c:52
void WINAPI EnterCriticalSection(LPCRITICAL_SECTION)
BOOL WINAPI DestroyWindow(_In_ HWND)
static DWORD urlmon_tls
Definition: urlmon_main.c:46
__WINE_SERVER_LIST_INLINE void list_remove(struct list *elem)
Definition: list.h:108
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
#define TLS_OUT_OF_INDEXES
Definition: winbase.h:530
LPVOID WINAPI TlsGetValue(IN DWORD Index)
Definition: thread.c:1228
void WINAPI LeaveCriticalSection(LPCRITICAL_SECTION)
static BOOL heap_free(void *mem)
Definition: appwiz.h:75

Referenced by DllMain().

◆ DllCanUnloadNow()

HRESULT WINAPI DllCanUnloadNow ( void  )

Definition at line 251 of file urlmon_main.c.

252 {
253  return URLMON_refCount != 0 ? S_FALSE : S_OK;
254 }
LONG URLMON_refCount
Definition: urlmon_main.c:42
#define S_FALSE
Definition: winerror.h:2357
#define S_OK
Definition: intsafe.h:59

◆ DllGetClassObject()

HRESULT WINAPI DllGetClassObject ( REFCLSID  rclsid,
REFIID  riid,
LPVOID ppv 
)

Definition at line 437 of file urlmon_main.c.

438 {
439  unsigned int i;
440  HRESULT hr;
441 
442  TRACE("(%s,%s,%p)\n", debugstr_guid(rclsid), debugstr_guid(riid), ppv);
443 
444  for (i = 0; i < ARRAY_SIZE(object_creation); i++)
445  {
446  if (IsEqualGUID(object_creation[i].clsid, rclsid))
447  return IClassFactory_QueryInterface(object_creation[i].cf, riid, ppv);
448  }
449 
450  hr = URLMON_DllGetClassObject(rclsid, riid, ppv);
451  if(SUCCEEDED(hr))
452  return hr;
453 
454  FIXME("%s: no class found.\n", debugstr_guid(rclsid));
456 }
HRESULT hr
Definition: shlfolder.c:183
REFIID riid
Definition: precomp.h:44
REFIID LPVOID * ppv
Definition: atlbase.h:39
static const struct object_creation_info object_creation[]
Definition: urlmon_main.c:393
#define CLASS_E_CLASSNOTAVAILABLE
Definition: winerror.h:2663
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
Definition: glfuncs.h:248
#define FIXME(fmt,...)
Definition: debug.h:110
#define debugstr_guid
Definition: kernel32.h:35
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:77
HRESULT WINAPI URLMON_DllGetClassObject(REFCLSID rclsid, REFIID iid, LPVOID *ppv) DECLSPEC_HIDDEN
REFCLSID clsid
Definition: msctf.c:82
#define ARRAY_SIZE(a)
Definition: main.h:24
BOOL WINAPI IsEqualGUID(REFGUID rguid1, REFGUID rguid2)
Definition: compobj.c:4112
#define SUCCEEDED(hr)
Definition: intsafe.h:57

◆ DllInstall()

HRESULT WINAPI DllInstall ( BOOL  bInstall,
LPCWSTR  cmdline 
)

Definition at line 240 of file urlmon_main.c.

241 {
242  FIXME("(%s, %s): stub\n", bInstall?"TRUE":"FALSE",
244 
245  return S_OK;
246 }
TCHAR * cmdline
Definition: stretchblt.cpp:32
#define debugstr_w
Definition: kernel32.h:32
#define FIXME(fmt,...)
Definition: debug.h:110
#define S_OK
Definition: intsafe.h:59

◆ DllMain()

BOOL WINAPI DllMain ( HINSTANCE  hinstDLL,
DWORD  fdwReason,
LPVOID  fImpLoad 
)

Definition at line 150 of file urlmon_main.c.

151 {
152  TRACE("%p 0x%x %p\n", hinstDLL, fdwReason, fImpLoad);
153 
154  URLMON_DllMain( hinstDLL, fdwReason, fImpLoad );
155 
156  switch(fdwReason) {
157  case DLL_PROCESS_ATTACH:
158  urlmon_instance = hinstDLL;
159  init_session();
160  break;
161 
162  case DLL_PROCESS_DETACH:
163  if (fImpLoad) break;
164  process_detach();
166  break;
167 
168  case DLL_THREAD_DETACH:
169  detach_thread();
170  break;
171  }
172  return TRUE;
173 }
#define TRUE
Definition: types.h:120
static CRITICAL_SECTION tls_cs
Definition: urlmon_main.c:52
#define DLL_PROCESS_ATTACH
Definition: compat.h:120
#define DLL_THREAD_DETACH
Definition: compat.h:122
static void process_detach(void)
Definition: urlmon_main.c:131
BOOL WINAPI URLMON_DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) DECLSPEC_HIDDEN
#define DLL_PROCESS_DETACH
Definition: compat.h:119
#define TRACE(s)
Definition: solgame.cpp:4
void WINAPI DeleteCriticalSection(PCRITICAL_SECTION)
HINSTANCE urlmon_instance
Definition: urlmon_main.c:43
static void init_session(void)
Definition: urlmon_main.c:408
DWORD LPVOID fImpLoad
Definition: misc.cpp:155
static void detach_thread(void)
Definition: urlmon_main.c:108

◆ DllRegisterServer()

HRESULT WINAPI DllRegisterServer ( void  )

Definition at line 474 of file urlmon_main.c.

475 {
476  HRESULT hr;
477 
478  TRACE("\n");
479 
481  return SUCCEEDED(hr) ? register_inf(TRUE) : hr;
482 }
HRESULT WINAPI URLMON_DllRegisterServer(void) DECLSPEC_HIDDEN
#define TRUE
Definition: types.h:120
HRESULT hr
Definition: shlfolder.c:183
static HRESULT register_inf(BOOL doregister)
Definition: urlmon_main.c:458
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:77
#define SUCCEEDED(hr)
Definition: intsafe.h:57

◆ DllRegisterServerEx()

HRESULT WINAPI DllRegisterServerEx ( void  )

Definition at line 500 of file urlmon_main.c.

501 {
502  FIXME("(void): stub\n");
503 
504  return E_FAIL;
505 }
#define E_FAIL
Definition: ddrawi.h:102
#define FIXME(fmt,...)
Definition: debug.h:110

◆ DllUnregisterServer()

HRESULT WINAPI DllUnregisterServer ( void  )

Definition at line 487 of file urlmon_main.c.

488 {
489  HRESULT hr;
490 
491  TRACE("\n");
492 
494  return SUCCEEDED(hr) ? register_inf(FALSE) : hr;
495 }
HRESULT hr
Definition: shlfolder.c:183
static HRESULT register_inf(BOOL doregister)
Definition: urlmon_main.c:458
HRESULT WINAPI URLMON_DllUnregisterServer(void) DECLSPEC_HIDDEN
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:77
#define SUCCEEDED(hr)
Definition: intsafe.h:57

◆ Extract()

HRESULT WINAPI Extract ( void dest,
LPCSTR  szCabName 
)

Definition at line 732 of file urlmon_main.c.

733 {
734  HRESULT (WINAPI *pExtract)(void *, LPCSTR);
735 
736  if (!hCabinet)
737  hCabinet = LoadLibraryA("cabinet.dll");
738 
739  if (!hCabinet) return HRESULT_FROM_WIN32(GetLastError());
740  pExtract = (void *)GetProcAddress(hCabinet, "Extract");
741  if (!pExtract) return HRESULT_FROM_WIN32(GetLastError());
742 
743  return pExtract(dest, szCabName);
744 }
#define HRESULT
Definition: msvc.h:9
#define HRESULT_FROM_WIN32(x)
Definition: winerror.h:92
DWORD WINAPI GetLastError(VOID)
Definition: except.c:1059
HINSTANCE WINAPI DECLSPEC_HOTPATCH LoadLibraryA(LPCSTR lpLibFileName)
Definition: loader.c:111
const char * LPCSTR
Definition: xmlstorage.h:183
static HMODULE hCabinet
Definition: urlmon_main.c:45
#define WINAPI
Definition: msvc.h:8
#define GetProcAddress(x, y)
Definition: compat.h:418
static char * dest
Definition: rtl.c:135

◆ FaultInIEFeature()

HRESULT WINAPI FaultInIEFeature ( HWND  hwnd,
uCLSSPEC *  pClassSpec,
QUERYCONTEXT *  pQuery,
DWORD  flags 
)

Definition at line 540 of file urlmon_main.c.

542 {
543  FIXME("%p %p %p %08x\n", hwnd, pClassSpec, pQuery, flags);
544  return E_NOTIMPL;
545 }
const DOCKBAR PVOID HWND HWND * hwnd
Definition: tooldock.h:22
#define FIXME(fmt,...)
Definition: debug.h:110
GLbitfield flags
Definition: glext.h:7161
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ FlushUrlmonZonesCache()

void WINAPI FlushUrlmonZonesCache ( void  )

Definition at line 827 of file urlmon_main.c.

828 {
829  FIXME("stub\n");
830 }
#define FIXME(fmt,...)
Definition: debug.h:110

◆ free_tls_list()

static void free_tls_list ( void  )
static

Definition at line 92 of file urlmon_main.c.

93 {
95 
97  return;
98 
99  while(!list_empty(&tls_list)) {
101  list_remove(&data->entry);
102  heap_free(data);
103  }
104 
106 }
static struct list tls_list
Definition: urlmon_main.c:50
__WINE_SERVER_LIST_INLINE struct list * list_head(const struct list *list)
Definition: list.h:131
static DWORD urlmon_tls
Definition: urlmon_main.c:46
__WINE_SERVER_LIST_INLINE void list_remove(struct list *elem)
Definition: list.h:108
BOOL WINAPI TlsFree(IN DWORD Index)
Definition: thread.c:1154
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
uint32_t entry
Definition: isohybrid.c:63
#define TLS_OUT_OF_INDEXES
Definition: winbase.h:530
__WINE_SERVER_LIST_INLINE int list_empty(const struct list *list)
Definition: list.h:143
#define LIST_ENTRY(type)
Definition: queue.h:175
static BOOL heap_free(void *mem)
Definition: appwiz.h:75

Referenced by process_detach().

◆ get_tls_data()

tls_data_t* get_tls_data ( void  )

Definition at line 62 of file urlmon_main.c.

63 {
65 
67  DWORD tls = TlsAlloc();
68  if(tls == TLS_OUT_OF_INDEXES)
69  return NULL;
70 
72  if(tls != urlmon_tls)
73  TlsFree(tls);
74  }
75 
77  if(!data) {
78  data = heap_alloc_zero(sizeof(tls_data_t));
79  if(!data)
80  return NULL;
81 
83  list_add_tail(&tls_list, &data->entry);
85 
87  }
88 
89  return data;
90 }
BOOL WINAPI TlsSetValue(IN DWORD Index, IN LPVOID Value)
Definition: thread.c:1264
static CRITICAL_SECTION tls_cs
Definition: urlmon_main.c:52
#define InterlockedCompareExchange
Definition: interlocked.h:104
static struct list tls_list
Definition: urlmon_main.c:50
void WINAPI EnterCriticalSection(LPCRITICAL_SECTION)
static DWORD urlmon_tls
Definition: urlmon_main.c:46
__WINE_SERVER_LIST_INLINE void list_add_tail(struct list *list, struct list *elem)
Definition: list.h:102
long LONG
Definition: pedump.c:60
smooth NULL
Definition: ftsmooth.c:416
BOOL WINAPI TlsFree(IN DWORD Index)
Definition: thread.c:1154
unsigned long DWORD
Definition: ntddk_ex.h:95
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
DWORD WINAPI TlsAlloc(VOID)
Definition: thread.c:1088
#define TLS_OUT_OF_INDEXES
Definition: winbase.h:530
LPVOID WINAPI TlsGetValue(IN DWORD Index)
Definition: thread.c:1228
static DWORD tls
Definition: sock.c:230
void WINAPI LeaveCriticalSection(LPCRITICAL_SECTION)

Referenced by get_notif_hwnd(), notif_wnd_proc(), and release_notif_hwnd().

◆ GetClassFileOrMime()

HRESULT WINAPI GetClassFileOrMime ( LPBC  pBC,
LPCWSTR  pszFilename,
LPVOID  pBuffer,
DWORD  cbBuffer,
LPCWSTR  pszMimeType,
DWORD  dwReserved,
CLSID pclsid 
)

Definition at line 720 of file urlmon_main.c.

723 {
724  FIXME("(%p, %s, %p, %d, %s, 0x%08x, %p): stub\n", pBC, debugstr_w(pszFilename), pBuffer,
725  cbBuffer, debugstr_w(pszMimeType), dwReserved, pclsid);
726  return E_NOTIMPL;
727 }
_In_ HANDLE _In_ DWORD _In_ DWORD _Inout_opt_ LPOVERLAPPED _In_opt_ LPTRANSMIT_FILE_BUFFERS _In_ DWORD dwReserved
Definition: mswsock.h:90
#define debugstr_w
Definition: kernel32.h:32
#define FIXME(fmt,...)
Definition: debug.h:110
PVOID pBuffer
#define E_NOTIMPL
Definition: ddrawi.h:99

◆ GetIUriPriv()

HRESULT WINAPI GetIUriPriv ( IUri uri,
void **  p 
)

Definition at line 857 of file urlmon_main.c.

858 {
859  FIXME("(%p,%p): stub\n", uri, p);
860  *p = NULL;
861  return E_NOTIMPL;
862 }
const char * uri
Definition: sec_mgr.c:1594
#define FIXME(fmt,...)
Definition: debug.h:110
smooth NULL
Definition: ftsmooth.c:416
#define E_NOTIMPL
Definition: ddrawi.h:99
GLfloat GLfloat p
Definition: glext.h:8902

◆ impl_from_IClassFactory()

static ClassFactory* impl_from_IClassFactory ( IClassFactory iface)
inlinestatic

Definition at line 267 of file urlmon_main.c.

268 {
269  return CONTAINING_RECORD(iface, ClassFactory, IClassFactory_iface);
270 }
PFLT_MESSAGE_WAITER_QUEUE CONTAINING_RECORD(Csq, DEVICE_EXTENSION, IrpQueue)) -> WaiterQ.mLock) _IRQL_raises_(DISPATCH_LEVEL) VOID NTAPI FltpAcquireMessageWaiterLock(_In_ PIO_CSQ Csq, _Out_ PKIRQL Irql)
Definition: Messaging.c:560

Referenced by CF_CreateInstance().

◆ init_session()

static void init_session ( void  )
static

Definition at line 408 of file urlmon_main.c.

409 {
410  unsigned int i;
411 
412  for(i = 0; i < ARRAY_SIZE(object_creation); i++) {
416  }
417 }
#define TRUE
Definition: types.h:120
static const struct object_creation_info object_creation[]
Definition: urlmon_main.c:393
HRESULT register_namespace(IClassFactory *cf, REFIID clsid, LPCWSTR protocol, BOOL urlmon_protocol)
Definition: session.c:122
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
Definition: glfuncs.h:248
REFCLSID clsid
Definition: msctf.c:82
#define ARRAY_SIZE(a)
Definition: main.h:24

Referenced by DllMain().

◆ IsLoggingEnabledA()

BOOL WINAPI IsLoggingEnabledA ( LPCSTR  url)

Definition at line 749 of file urlmon_main.c.

750 {
751  FIXME("(%s)\n", debugstr_a(url));
752  return FALSE;
753 }
#define FIXME(fmt,...)
Definition: debug.h:110
#define debugstr_a
Definition: kernel32.h:31
static const WCHAR url[]
Definition: encode.c:1432

◆ IsLoggingEnabledW()

BOOL WINAPI IsLoggingEnabledW ( LPCWSTR  url)

Definition at line 758 of file urlmon_main.c.

759 {
760  FIXME("(%s)\n", debugstr_w(url));
761  return FALSE;
762 }
#define debugstr_w
Definition: kernel32.h:32
#define FIXME(fmt,...)
Definition: debug.h:110
static const WCHAR url[]
Definition: encode.c:1432

◆ IsProtectedModeURL()

BOOL WINAPI IsProtectedModeURL ( const WCHAR url)

Definition at line 768 of file urlmon_main.c.

769 {
770  FIXME("stub: %s\n", debugstr_w(url));
771  return TRUE;
772 }
#define TRUE
Definition: types.h:120
#define debugstr_w
Definition: kernel32.h:32
#define FIXME(fmt,...)
Definition: debug.h:110
static const WCHAR url[]
Definition: encode.c:1432

◆ IsValidURL()

HRESULT WINAPI IsValidURL ( LPBC  pBC,
LPCWSTR  szURL,
DWORD  dwReserved 
)

Definition at line 525 of file urlmon_main.c.

526 {
527  FIXME("(%p, %s, %d): stub\n", pBC, debugstr_w(szURL), dwReserved);
528 
529  if (dwReserved || !szURL)
530  return E_INVALIDARG;
531 
532  return S_OK;
533 }
_In_ HANDLE _In_ DWORD _In_ DWORD _Inout_opt_ LPOVERLAPPED _In_opt_ LPTRANSMIT_FILE_BUFFERS _In_ DWORD dwReserved
Definition: mswsock.h:90
#define debugstr_w
Definition: kernel32.h:32
#define FIXME(fmt,...)
Definition: debug.h:110
#define E_INVALIDARG
Definition: ddrawi.h:101
#define S_OK
Definition: intsafe.h:59

Referenced by test_IsValidURL().

◆ LogSqmBits()

int WINAPI LogSqmBits ( DWORD  unk1,
DWORD  unk2 
)

Definition at line 778 of file urlmon_main.c.

779 {
780  FIXME("stub: %d %d\n", unk1, unk2);
781  return 0;
782 }
static DWORD unk1
Definition: cursoricon.c:1638
#define FIXME(fmt,...)
Definition: debug.h:110

◆ LogSqmUXCommandOffsetInternal()

void WINAPI LogSqmUXCommandOffsetInternal ( DWORD  unk1,
DWORD  unk2,
DWORD  unk3,
DWORD  unk4 
)

Definition at line 788 of file urlmon_main.c.

789 {
790  FIXME("stub: %d %d %d %d\n", unk1, unk2, unk3, unk4);
791 }
static DWORD unk1
Definition: cursoricon.c:1638
#define FIXME(fmt,...)
Definition: debug.h:110

◆ MapBrowserEmulationModeToUserAgent()

int WINAPI MapBrowserEmulationModeToUserAgent ( DWORD  unk1,
DWORD  unk2 
)

Definition at line 807 of file urlmon_main.c.

808 {
809  FIXME("stub: %d %d\n", unk1, unk2);
810  return 0;
811 }
static DWORD unk1
Definition: cursoricon.c:1638
#define FIXME(fmt,...)
Definition: debug.h:110

◆ MapUriToBrowserEmulationState()

int WINAPI MapUriToBrowserEmulationState ( DWORD  unk1,
DWORD  unk2,
DWORD  unk3 
)

Definition at line 797 of file urlmon_main.c.

798 {
799  FIXME("stub: %d %d %d\n", unk1, unk2, unk3);
800  return 0;
801 }
static DWORD unk1
Definition: cursoricon.c:1638
#define FIXME(fmt,...)
Definition: debug.h:110

◆ process_detach()

static void process_detach ( void  )
static

Definition at line 131 of file urlmon_main.c.

132 {
134 
136  if(internet_session)
138 
139  if (hCabinet)
141 
142  free_session();
143  free_tls_list();
145 }
void free_session(void)
Definition: session.c:755
static HINTERNET internet_session
Definition: protocol.c:288
BOOL WINAPI InternetCloseHandle(HINTERNET hInternet)
Definition: internet.c:1437
smooth NULL
Definition: ftsmooth.c:416
#define FreeLibrary(x)
Definition: compat.h:413
static HMODULE hCabinet
Definition: urlmon_main.c:45
HINTERNET get_internet_session(IInternetBindInfo *bind_info)
Definition: protocol.c:290
static void free_tls_list(void)
Definition: urlmon_main.c:92
void unregister_notif_wnd_class(void)
Definition: bindprot.c:105

Referenced by DllMain().

◆ register_inf()

static HRESULT register_inf ( BOOL  doregister)
static

Definition at line 458 of file urlmon_main.c.

459 {
460  HRESULT (WINAPI *pRegInstall)(HMODULE hm, LPCSTR pszSection, const STRTABLEA* pstTable);
461  HMODULE hAdvpack;
462 
463  static const WCHAR wszAdvpack[] = {'a','d','v','p','a','c','k','.','d','l','l',0};
464 
465  hAdvpack = LoadLibraryW(wszAdvpack);
466  pRegInstall = (void *)GetProcAddress(hAdvpack, "RegInstall");
467 
468  return pRegInstall(hProxyDll, doregister ? "RegisterDll" : "UnregisterDll", NULL);
469 }
#define HRESULT
Definition: msvc.h:9
#define LoadLibraryW(x)
Definition: compat.h:412
smooth NULL
Definition: ftsmooth.c:416
const char * LPCSTR
Definition: xmlstorage.h:183
__wchar_t WCHAR
Definition: xmlstorage.h:180
#define WINAPI
Definition: msvc.h:8
#define GetProcAddress(x, y)
Definition: compat.h:418

Referenced by DllRegisterServer(), and DllUnregisterServer().

◆ RegisterMediaTypes()

HRESULT WINAPI RegisterMediaTypes ( UINT  types,
LPCSTR szTypes,
CLIPFORMAT *  cfTypes 
)

Definition at line 836 of file urlmon_main.c.

837 {
838  FIXME("stub: %u %p %p\n", types, szTypes, cfTypes);
839  return E_INVALIDARG;
840 }
#define FIXME(fmt,...)
Definition: debug.h:110
#define E_INVALIDARG
Definition: ddrawi.h:101
Definition: cmds.c:130

◆ ReleaseBindInfo()

void WINAPI ReleaseBindInfo ( BINDINFO *  pbindinfo)

Definition at line 572 of file urlmon_main.c.

573 {
574  DWORD size;
575 
576  TRACE("(%p)\n", pbindinfo);
577 
578  if(!pbindinfo || !(size = pbindinfo->cbSize))
579  return;
580 
581  CoTaskMemFree(pbindinfo->szExtraInfo);
582  ReleaseStgMedium(&pbindinfo->stgmedData);
583 
584  if(offsetof(BINDINFO, szExtraInfo) < size)
585  CoTaskMemFree(pbindinfo->szCustomVerb);
586 
587  if(pbindinfo->pUnk && offsetof(BINDINFO, pUnk) < size)
588  IUnknown_Release(pbindinfo->pUnk);
589 
590  memset(pbindinfo, 0, size);
591  pbindinfo->cbSize = size;
592 }
VOID WINAPI CoTaskMemFree(LPVOID ptr)
Definition: ifs.c:420
void WINAPI ReleaseStgMedium(STGMEDIUM *pmedium)
Definition: ole2.c:2033
#define offsetof(TYPE, MEMBER)
#define TRACE(s)
Definition: solgame.cpp:4
GLsizeiptr size
Definition: glext.h:5919
unsigned long DWORD
Definition: ntddk_ex.h:95
#define memset(x, y, z)
Definition: compat.h:39
static void *static void *static LPDIRECTPLAY IUnknown * pUnk
Definition: dplayx.c:30

Referenced by AboutProtocol_Start(), Binding_Release(), DownloadBSC_GetBindInfo(), FileProtocol_StartEx(), internet_status_callback(), ITSProtocol_Start(), MkProtocol_StartEx(), navigate_hlink(), ResProtocol_Start(), and test_bsc_marshaling().

◆ ShouldShowIntranetWarningSecband()

BOOL WINAPI ShouldShowIntranetWarningSecband ( DWORD  unk)

Definition at line 846 of file urlmon_main.c.

847 {
848  FIXME("%x: stub\n", unk);
849  return FALSE;
850 }
#define FIXME(fmt,...)
Definition: debug.h:110

◆ WINE_DEFAULT_DEBUG_CHANNEL()

WINE_DEFAULT_DEBUG_CHANNEL ( urlmon  )

Variable Documentation

◆ ClassFactoryVtbl

const IClassFactoryVtbl ClassFactoryVtbl
static
Initial value:
=
{
}
static ULONG WINAPI CF_AddRef(IClassFactory *iface)
Definition: urlmon_main.c:293
static HRESULT WINAPI CF_CreateInstance(IClassFactory *iface, IUnknown *outer, REFIID riid, void **ppv)
Definition: urlmon_main.c:306
static HRESULT WINAPI CF_LockServer(LPCLASSFACTORY iface, BOOL dolock)
Definition: urlmon_main.c:335
static ULONG WINAPI CF_Release(IClassFactory *iface)
Definition: urlmon_main.c:299
static HRESULT WINAPI CF_QueryInterface(IClassFactory *iface, REFIID riid, LPVOID *ppv)
Definition: urlmon_main.c:272

Definition at line 347 of file urlmon_main.c.

◆ CUriCF

ClassFactory CUriCF
static
Initial value:
=
static const IClassFactoryVtbl ClassFactoryVtbl
Definition: urlmon_main.c:347
HRESULT Uri_Construct(IUnknown *pUnkOuter, LPVOID *ppobj)
Definition: uri.c:5656

Definition at line 376 of file urlmon_main.c.

◆ FileProtocolCF

ClassFactory FileProtocolCF
static
Initial value:
=
static const IClassFactoryVtbl ClassFactoryVtbl
Definition: urlmon_main.c:347
HRESULT FileProtocol_Construct(IUnknown *outer, LPVOID *ppobj)
Definition: file.c:421

Definition at line 356 of file urlmon_main.c.

◆ FtpProtocolCF

ClassFactory FtpProtocolCF
static
Initial value:
=
HRESULT FtpProtocol_Construct(IUnknown *outer, void **ppv)
Definition: ftp.c:454
static const IClassFactoryVtbl ClassFactoryVtbl
Definition: urlmon_main.c:347

Definition at line 358 of file urlmon_main.c.

◆ GopherProtocolCF

ClassFactory GopherProtocolCF
static
Initial value:
=
static const IClassFactoryVtbl ClassFactoryVtbl
Definition: urlmon_main.c:347
HRESULT GopherProtocol_Construct(IUnknown *pUnkOuter, LPVOID *ppobj)
Definition: gopher.c:312

Definition at line 360 of file urlmon_main.c.

◆ hCabinet

HMODULE hCabinet = NULL
static

Definition at line 45 of file urlmon_main.c.

Referenced by Extract(), ExtractFilesA(), and process_detach().

◆ HttpProtocolCF

ClassFactory HttpProtocolCF
static
Initial value:
=
static const IClassFactoryVtbl ClassFactoryVtbl
Definition: urlmon_main.c:347
HRESULT HttpProtocol_Construct(IUnknown *outer, void **ppv)
Definition: http.c:985

Definition at line 362 of file urlmon_main.c.

◆ HttpSProtocolCF

ClassFactory HttpSProtocolCF
static
Initial value:
=
static const IClassFactoryVtbl ClassFactoryVtbl
Definition: urlmon_main.c:347
HRESULT HttpSProtocol_Construct(IUnknown *outer, void **ppv)
Definition: http.c:992

Definition at line 364 of file urlmon_main.c.

◆ MimeFilterCF

ClassFactory MimeFilterCF
static
Initial value:
=
static const IClassFactoryVtbl ClassFactoryVtbl
Definition: urlmon_main.c:347
HRESULT MimeFilter_Construct(IUnknown *pUnkOuter, LPVOID *ppobj)
Definition: mimefilter.c:246

Definition at line 374 of file urlmon_main.c.

◆ MkProtocolCF

ClassFactory MkProtocolCF
static
Initial value:
=
static const IClassFactoryVtbl ClassFactoryVtbl
Definition: urlmon_main.c:347
HRESULT MkProtocol_Construct(IUnknown *outer, void **ppv)
Definition: mk.c:365

Definition at line 366 of file urlmon_main.c.

◆ object_creation

const struct object_creation_info object_creation[]
static
Initial value:
=
{
{ &CLSID_FileProtocol, &FileProtocolCF.IClassFactory_iface, wszFile },
{ &CLSID_FtpProtocol, &FtpProtocolCF.IClassFactory_iface, wszFtp },
{ &CLSID_GopherProtocol, &GopherProtocolCF.IClassFactory_iface, wszGopher },
{ &CLSID_HttpProtocol, &HttpProtocolCF.IClassFactory_iface, wszHttp },
{ &CLSID_HttpSProtocol, &HttpSProtocolCF.IClassFactory_iface, wszHttps },
{ &CLSID_MkProtocol, &MkProtocolCF.IClassFactory_iface, wszMk },
{ &CLSID_InternetSecurityManager, &SecurityManagerCF.IClassFactory_iface, NULL },
{ &CLSID_InternetZoneManager, &ZoneManagerCF.IClassFactory_iface, NULL },
{ &CLSID_StdURLMoniker, &StdURLMonikerCF.IClassFactory_iface, NULL },
{ &CLSID_DeCompMimeFilter, &MimeFilterCF.IClassFactory_iface, NULL },
{ &CLSID_CUri, &CUriCF.IClassFactory_iface, NULL }
}
static const WCHAR wszHttp[]
Definition: urlmon_main.c:389
static ClassFactory StdURLMonikerCF
Definition: urlmon_main.c:372
static ClassFactory GopherProtocolCF
Definition: urlmon_main.c:360
static const WCHAR wszHttps[]
Definition: urlmon_main.c:390
static const WCHAR wszGopher[]
Definition: urlmon_main.c:388
static const WCHAR wszFile[]
Definition: urlmon_main.c:386
static const WCHAR wszMk[]
Definition: urlmon_main.c:391
smooth NULL
Definition: ftsmooth.c:416
static ClassFactory CUriCF
Definition: urlmon_main.c:376
static ClassFactory HttpSProtocolCF
Definition: urlmon_main.c:364
static ClassFactory HttpProtocolCF
Definition: urlmon_main.c:362
static ClassFactory FtpProtocolCF
Definition: urlmon_main.c:358
static ClassFactory SecurityManagerCF
Definition: urlmon_main.c:368
static ClassFactory MkProtocolCF
Definition: urlmon_main.c:366
static ClassFactory ZoneManagerCF
Definition: urlmon_main.c:370
static ClassFactory FileProtocolCF
Definition: urlmon_main.c:356
static ClassFactory MimeFilterCF
Definition: urlmon_main.c:374
IClassFactory IClassFactory_iface
Definition: main.c:203
static const WCHAR wszFtp[]
Definition: urlmon_main.c:387

Definition at line 393 of file urlmon_main.c.

Referenced by DllGetClassObject(), and init_session().

◆ SecurityManagerCF

ClassFactory SecurityManagerCF
static
Initial value:
=
static const IClassFactoryVtbl ClassFactoryVtbl
Definition: urlmon_main.c:347
HRESULT SecManagerImpl_Construct(IUnknown *pUnkOuter, LPVOID *ppobj)
Definition: sec_mgr.c:1241

Definition at line 368 of file urlmon_main.c.

◆ StdURLMonikerCF

ClassFactory StdURLMonikerCF
static
Initial value:
=
static const IClassFactoryVtbl ClassFactoryVtbl
Definition: urlmon_main.c:347
HRESULT StdURLMoniker_Construct(IUnknown *outer, void **ppv)
Definition: umon.c:573

Definition at line 372 of file urlmon_main.c.

◆ tls_cs

static CRITICAL_SECTION tls_cs = { &tls_cs_dbg, -1, 0, 0, 0, 0 }
static

Definition at line 52 of file urlmon_main.c.

Referenced by detach_thread(), DllMain(), and get_tls_data().

◆ tls_cs_dbg

CRITICAL_SECTION_DEBUG tls_cs_dbg
static
Initial value:
=
{
0, 0, &tls_cs,
0, 0, { (DWORD_PTR)(__FILE__ ": tls") }
}
#define DWORD_PTR
Definition: treelist.c:76
static CRITICAL_SECTION tls_cs
Definition: urlmon_main.c:52
static CRITICAL_SECTION_DEBUG tls_cs_dbg
Definition: urlmon_main.c:53
LIST_ENTRY ProcessLocksList
Definition: winbase.h:855

Definition at line 53 of file urlmon_main.c.

◆ tls_list

struct list tls_list = LIST_INIT(tls_list)
static

Definition at line 50 of file urlmon_main.c.

Referenced by free_tls_list(), and get_tls_data().

◆ urlmon_instance

HINSTANCE urlmon_instance

Definition at line 43 of file urlmon_main.c.

Referenced by DllMain(), failure_msgbox(), install_warning(), and update_counter().

◆ URLMON_refCount

LONG URLMON_refCount = 0

Definition at line 42 of file urlmon_main.c.

Referenced by DllCanUnloadNow(), URLMON_LockModule(), and URLMON_UnlockModule().

◆ urlmon_tls

DWORD urlmon_tls = TLS_OUT_OF_INDEXES
static

Definition at line 46 of file urlmon_main.c.

Referenced by detach_thread(), free_tls_list(), and get_tls_data().

◆ wszFile

◆ wszFtp

const WCHAR wszFtp[] = {'f','t','p',0}
static

Definition at line 387 of file urlmon_main.c.

Referenced by hyperlink_dlgproc().

◆ wszGopher

const WCHAR wszGopher[] = {'g','o','p','h','e','r',0}
static

Definition at line 388 of file urlmon_main.c.

◆ wszHttp

const WCHAR wszHttp[] = {'h','t','t','p',0}
static

Definition at line 389 of file urlmon_main.c.

Referenced by hyperlink_dlgproc(), and UrlCanonicalizeW().

◆ wszHttps

const WCHAR wszHttps[] = {'h','t','t','p','s',0}
static

Definition at line 390 of file urlmon_main.c.

Referenced by hyperlink_dlgproc().

◆ wszMk

const WCHAR wszMk[] = {'m','k',0}
static

Definition at line 391 of file urlmon_main.c.

◆ ZoneManagerCF

ClassFactory ZoneManagerCF
static
Initial value:
=
HRESULT ZoneMgrImpl_Construct(IUnknown *pUnkOuter, LPVOID *ppobj)
Definition: sec_mgr.c:1823
static const IClassFactoryVtbl ClassFactoryVtbl
Definition: urlmon_main.c:347

Definition at line 370 of file urlmon_main.c.