ReactOS  0.4.15-dev-484-g89e716a7
node.cpp File Reference
#include "precomp.h"
Include dependency graph for node.cpp:

Go to the source code of this file.

Classes

class  CKsNode
 

Functions

HRESULT WINAPI CKsNode_Constructor (IUnknown *pUnkOuter, HANDLE ParentHandle, ULONG NodeId, ACCESS_MASK DesiredAccess, REFIID riid, LPVOID *ppv)
 

Function Documentation

◆ CKsNode_Constructor()

HRESULT WINAPI CKsNode_Constructor ( IUnknown pUnkOuter,
HANDLE  ParentHandle,
ULONG  NodeId,
ACCESS_MASK  DesiredAccess,
REFIID  riid,
LPVOID ppv 
)

Definition at line 115 of file node.cpp.

122 {
123  HRESULT hr;
124  HANDLE handle;
126 
127 #ifdef KSPROXY_TRACE
128  OutputDebugStringW(L"CKsNode_Constructor\n");
129 #endif
130 
131  //setup request
133  NodeCreate.Node = NodeId;
134 
136  if (hr != NOERROR)
137  {
138  OutputDebugString("CKsNode_Constructor failed to open device\n");
140  }
141 
142  CKsNode * quality = new CKsNode(pUnkOuter, handle);
143 
144  if (!quality)
145  {
146  // free clock handle
148  return E_OUTOFMEMORY;
149  }
150 
151  if (FAILED(quality->QueryInterface(riid, ppv)))
152  {
153  /* not supported */
154  delete quality;
155  return E_NOINTERFACE;
156  }
157 
158  return NOERROR;
159 }
namespace GUID const ADDRINFOEXW ADDRINFOEXW struct timeval OVERLAPPED LPLOOKUPSERVICE_COMPLETION_ROUTINE HANDLE * handle
Definition: sock.c:82
#define CloseHandle
Definition: compat.h:407
#define E_NOINTERFACE
Definition: winerror.h:2364
HRESULT hr
Definition: shlfolder.c:183
#define NOERROR
Definition: winerror.h:2354
_In_ PKSNODE_CREATE NodeCreate
Definition: ks.h:4546
REFIID riid
Definition: precomp.h:44
REFIID LPVOID * ppv
Definition: atlbase.h:39
Definition: node.cpp:11
#define OutputDebugString
Definition: winbase.h:3730
void WINAPI SHIM_OBJ_NAME() OutputDebugStringW(LPCWSTR lpOutputString)
Definition: ignoredbgout.c:23
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
KSDDKAPI DWORD NTAPI KsCreateTopologyNode(HANDLE ParentHandle, PKSNODE_CREATE NodeCreate, IN ACCESS_MASK DesiredAccess, OUT PHANDLE NodeHandle)
Definition: ksuser.c:240
#define MAKE_HRESULT(sev, fac, code)
Definition: dmerror.h:30
ULONG Node
Definition: ks.h:2094
LONG HRESULT
Definition: typedefs.h:78
int quality
Definition: jpeglib.h:992
#define SEVERITY_ERROR
Definition: winerror.h:65
static const WCHAR L[]
Definition: oid.c:1250
#define FACILITY_WIN32
Definition: winerror.h:27
_In_ PIO_STACK_LOCATION _Inout_ PFILE_OBJECT _Inout_ PVCB _Outptr_result_maybenull_ PDCB _In_ PDCB _In_ PDIRENT _In_ ULONG _In_ ULONG _In_ PUNICODE_STRING _In_ PACCESS_MASK DesiredAccess
Definition: create.c:4137
ULONG CreateFlags
Definition: ks.h:2093

Referenced by CKsProxy::CreateNodeInstance().