ReactOS  0.4.15-dev-1397-g19779b3
filelockbytes.c File Reference
#include <assert.h>
#include <stdlib.h>
#include <stdarg.h>
#include <stdio.h>
#include <string.h>
#include <limits.h>
#include "windef.h"
#include "winbase.h"
#include "winuser.h"
#include "winerror.h"
#include "objbase.h"
#include "ole2.h"
#include "storage32.h"
#include "wine/debug.h"
Include dependency graph for filelockbytes.c:

Go to the source code of this file.

Classes

struct  FileLockBytesImpl
 

Macros

#define COBJMACROS
 
#define NONAMELESSUNION
 
#define NONAMELESSSTRUCT
 

Typedefs

typedef struct FileLockBytesImpl FileLockBytesImpl
 

Functions

 WINE_DEFAULT_DEBUG_CHANNEL (storage)
 
static FileLockBytesImplimpl_from_ILockBytes (ILockBytes *iface)
 
static DWORD GetProtectMode (DWORD openFlags)
 
HRESULT FileLockBytesImpl_Construct (HANDLE hFile, DWORD openFlags, LPCWSTR pwcsName, ILockBytes **pLockBytes)
 
static HRESULT WINAPI FileLockBytesImpl_QueryInterface (ILockBytes *iface, REFIID riid, void **ppvObject)
 
static ULONG WINAPI FileLockBytesImpl_AddRef (ILockBytes *iface)
 
static ULONG WINAPI FileLockBytesImpl_Release (ILockBytes *iface)
 
static HRESULT WINAPI FileLockBytesImpl_ReadAt (ILockBytes *iface, ULARGE_INTEGER ulOffset, void *pv, ULONG cb, ULONG *pcbRead)
 
static HRESULT WINAPI FileLockBytesImpl_WriteAt (ILockBytes *iface, ULARGE_INTEGER ulOffset, const void *pv, ULONG cb, ULONG *pcbWritten)
 
static HRESULT WINAPI FileLockBytesImpl_Flush (ILockBytes *iface)
 
static HRESULT WINAPI FileLockBytesImpl_SetSize (ILockBytes *iface, ULARGE_INTEGER newSize)
 
static HRESULT get_lock_error (void)
 
static HRESULT WINAPI FileLockBytesImpl_LockRegion (ILockBytes *iface, ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType)
 
static HRESULT WINAPI FileLockBytesImpl_UnlockRegion (ILockBytes *iface, ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType)
 
static HRESULT WINAPI FileLockBytesImpl_Stat (ILockBytes *iface, STATSTG *pstatstg, DWORD grfStatFlag)
 

Variables

static const ILockBytesVtbl FileLockBytesImpl_Vtbl
 

Macro Definition Documentation

◆ COBJMACROS

#define COBJMACROS

Definition at line 30 of file filelockbytes.c.

◆ NONAMELESSSTRUCT

#define NONAMELESSSTRUCT

Definition at line 32 of file filelockbytes.c.

◆ NONAMELESSUNION

#define NONAMELESSUNION

Definition at line 31 of file filelockbytes.c.

Typedef Documentation

◆ FileLockBytesImpl

Function Documentation

◆ FileLockBytesImpl_AddRef()

static ULONG WINAPI FileLockBytesImpl_AddRef ( ILockBytes iface)
static

Definition at line 147 of file filelockbytes.c.

148 {
150  return InterlockedIncrement(&This->ref);
151 }
static FileLockBytesImpl * impl_from_ILockBytes(ILockBytes *iface)
Definition: filelockbytes.c:58
#define InterlockedIncrement
Definition: armddk.h:53

◆ FileLockBytesImpl_Construct()

HRESULT FileLockBytesImpl_Construct ( HANDLE  hFile,
DWORD  openFlags,
LPCWSTR  pwcsName,
ILockBytes **  pLockBytes 
)

Definition at line 89 of file filelockbytes.c.

90 {
92  WCHAR fullpath[MAX_PATH];
93 
95  return E_FAIL;
96 
98 
99  if (!This)
100  return E_OUTOFMEMORY;
101 
102  This->ILockBytes_iface.lpVtbl = &FileLockBytesImpl_Vtbl;
103  This->ref = 1;
104  This->hfile = hFile;
105  This->flProtect = GetProtectMode(openFlags);
106 
107  if(pwcsName) {
108  if (!GetFullPathNameW(pwcsName, MAX_PATH, fullpath, NULL))
109  {
110  lstrcpynW(fullpath, pwcsName, MAX_PATH);
111  }
112  This->pwcsName = HeapAlloc(GetProcessHeap(), 0,
113  (lstrlenW(fullpath)+1)*sizeof(WCHAR));
114  if (!This->pwcsName)
115  {
117  return E_OUTOFMEMORY;
118  }
119  lstrcpyW(This->pwcsName, fullpath);
120  }
121  else
122  This->pwcsName = NULL;
123 
124  *pLockBytes = &This->ILockBytes_iface;
125 
126  return S_OK;
127 }
static DWORD GetProtectMode(DWORD openFlags)
Definition: filelockbytes.c:73
#define INVALID_HANDLE_VALUE
Definition: compat.h:590
DWORD WINAPI GetFullPathNameW(IN LPCWSTR lpFileName, IN DWORD nBufferLength, OUT LPWSTR lpBuffer, OUT LPWSTR *lpFilePart)
Definition: path.c:1105
#define lstrlenW
Definition: compat.h:609
#define E_FAIL
Definition: ddrawi.h:102
#define lstrcpynW
Definition: compat.h:597
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
#define GetProcessHeap()
Definition: compat.h:595
PVOID WINAPI HeapAlloc(HANDLE, DWORD, SIZE_T)
__wchar_t WCHAR
Definition: xmlstorage.h:180
#define MAX_PATH
Definition: compat.h:34
_In_ HANDLE hFile
Definition: mswsock.h:90
#define S_OK
Definition: intsafe.h:51
#define lstrcpyW
Definition: compat.h:608
static const ILockBytesVtbl FileLockBytesImpl_Vtbl
Definition: filelockbytes.c:56
#define NULL
Definition: types.h:112
#define HeapFree(x, y, z)
Definition: compat.h:594

Referenced by StorageImpl_Construct().

◆ FileLockBytesImpl_Flush()

static HRESULT WINAPI FileLockBytesImpl_Flush ( ILockBytes iface)
static

Definition at line 283 of file filelockbytes.c.

284 {
285  return S_OK;
286 }
#define S_OK
Definition: intsafe.h:51

◆ FileLockBytesImpl_LockRegion()

static HRESULT WINAPI FileLockBytesImpl_LockRegion ( ILockBytes iface,
ULARGE_INTEGER  libOffset,
ULARGE_INTEGER  cb,
DWORD  dwLockType 
)
static

Definition at line 324 of file filelockbytes.c.

326 {
328  OVERLAPPED ol;
329  DWORD lock_flags = LOCKFILE_FAIL_IMMEDIATELY;
330 
331  TRACE("ofs %u count %u flags %x\n", libOffset.u.LowPart, cb.u.LowPart, dwLockType);
332 
333  if (dwLockType & LOCK_WRITE)
334  return STG_E_INVALIDFUNCTION;
335 
336  if (dwLockType & (LOCK_EXCLUSIVE|LOCK_ONLYONCE))
337  lock_flags |= LOCKFILE_EXCLUSIVE_LOCK;
338 
339  ol.hEvent = 0;
340  ol.u.s.Offset = libOffset.u.LowPart;
341  ol.u.s.OffsetHigh = libOffset.u.HighPart;
342 
343  if (LockFileEx(This->hfile, lock_flags, 0, cb.u.LowPart, cb.u.HighPart, &ol))
344  return S_OK;
345  return get_lock_error();
346 }
static FileLockBytesImpl * impl_from_ILockBytes(ILockBytes *iface)
Definition: filelockbytes.c:58
DWORD Offset
Definition: winbase.h:793
HANDLE hEvent
Definition: winbase.h:798
#define LOCKFILE_FAIL_IMMEDIATELY
Definition: winbase.h:366
#define STG_E_INVALIDFUNCTION
Definition: winerror.h:2564
struct _ULARGE_INTEGER::@3949 u
#define TRACE(s)
Definition: solgame.cpp:4
unsigned long DWORD
Definition: ntddk_ex.h:95
#define S_OK
Definition: intsafe.h:51
BOOL WINAPI LockFileEx(IN HANDLE hFile, IN DWORD dwFlags, IN DWORD dwReserved, IN DWORD nNumberOfBytesToLockLow, IN DWORD nNumberOfBytesToLockHigh, IN LPOVERLAPPED lpOverlapped)
Definition: lock.c:82
DWORD OffsetHigh
Definition: winbase.h:794
static HRESULT get_lock_error(void)
#define LOCKFILE_EXCLUSIVE_LOCK
Definition: winbase.h:367
static HMODULE MODULEINFO DWORD cb
Definition: module.c:32

◆ FileLockBytesImpl_QueryInterface()

static HRESULT WINAPI FileLockBytesImpl_QueryInterface ( ILockBytes iface,
REFIID  riid,
void **  ppvObject 
)
static

Definition at line 131 of file filelockbytes.c.

133 {
134  if (IsEqualIID(riid, &IID_IUnknown) || IsEqualIID(riid, &IID_ILockBytes))
135  *ppvObject = iface;
136  else
137  {
138  *ppvObject = NULL;
139  return E_NOINTERFACE;
140  }
141 
142  IUnknown_AddRef((IUnknown*)*ppvObject);
143 
144  return S_OK;
145 }
#define E_NOINTERFACE
Definition: winerror.h:2364
REFIID riid
Definition: precomp.h:44
const GUID IID_IUnknown
REFIID LPVOID * ppvObject
Definition: precomp.h:44
#define S_OK
Definition: intsafe.h:51
#define NULL
Definition: types.h:112
#define IsEqualIID(riid1, riid2)
Definition: guiddef.h:95

◆ FileLockBytesImpl_ReadAt()

static HRESULT WINAPI FileLockBytesImpl_ReadAt ( ILockBytes iface,
ULARGE_INTEGER  ulOffset,
void pv,
ULONG  cb,
ULONG pcbRead 
)
static

Definition at line 178 of file filelockbytes.c.

184 {
186  ULONG bytes_left = cb;
187  LPBYTE readPtr = pv;
188  BOOL ret;
190  ULONG cbRead;
191 
192  TRACE("(%p)-> %i %p %i %p\n",This, ulOffset.u.LowPart, pv, cb, pcbRead);
193 
194  /* verify a sane environment */
195  if (!This) return E_FAIL;
196 
197  if (pcbRead)
198  *pcbRead = 0;
199 
200  offset.QuadPart = ulOffset.QuadPart;
201 
203 
204  if (!ret)
205  return STG_E_READFAULT;
206 
207  while (bytes_left)
208  {
209  ret = ReadFile(This->hfile, readPtr, bytes_left, &cbRead, NULL);
210 
211  if (!ret || cbRead == 0)
212  return STG_E_READFAULT;
213 
214  if (pcbRead)
215  *pcbRead += cbRead;
216 
217  bytes_left -= cbRead;
218  readPtr += cbRead;
219  }
220 
221  TRACE("finished\n");
222  return S_OK;
223 }
static FileLockBytesImpl * impl_from_ILockBytes(ILockBytes *iface)
Definition: filelockbytes.c:58
BOOL WINAPI SetFilePointerEx(HANDLE hFile, LARGE_INTEGER liDistanceToMove, PLARGE_INTEGER lpNewFilePointer, DWORD dwMoveMethod)
Definition: fileinfo.c:177
#define FILE_BEGIN
Definition: compat.h:620
#define E_FAIL
Definition: ddrawi.h:102
unsigned char * LPBYTE
Definition: typedefs.h:53
ULONGLONG QuadPart
Definition: ms-dtyp.idl:185
unsigned int BOOL
Definition: ntddk_ex.h:94
struct _ULARGE_INTEGER::@3949 u
#define TRACE(s)
Definition: solgame.cpp:4
GLintptr offset
Definition: glext.h:5920
int ret
#define S_OK
Definition: intsafe.h:51
#define ReadFile(a, b, c, d, e)
Definition: compat.h:601
#define STG_E_READFAULT
Definition: winerror.h:2576
#define NULL
Definition: types.h:112
static HMODULE MODULEINFO DWORD cb
Definition: module.c:32
unsigned int ULONG
Definition: retypes.h:1

◆ FileLockBytesImpl_Release()

static ULONG WINAPI FileLockBytesImpl_Release ( ILockBytes iface)
static

Definition at line 153 of file filelockbytes.c.

154 {
156  ULONG ref;
157 
158  ref = InterlockedDecrement(&This->ref);
159 
160  if (ref == 0)
161  {
162  CloseHandle(This->hfile);
163  HeapFree(GetProcessHeap(), 0, This->pwcsName);
165  }
166 
167  return ref;
168 }
static FileLockBytesImpl * impl_from_ILockBytes(ILockBytes *iface)
Definition: filelockbytes.c:58
#define CloseHandle
Definition: compat.h:598
Definition: send.c:48
GLenum GLint ref
Definition: glext.h:6028
#define GetProcessHeap()
Definition: compat.h:595
#define InterlockedDecrement
Definition: armddk.h:52
unsigned int ULONG
Definition: retypes.h:1
#define HeapFree(x, y, z)
Definition: compat.h:594

◆ FileLockBytesImpl_SetSize()

static HRESULT WINAPI FileLockBytesImpl_SetSize ( ILockBytes iface,
ULARGE_INTEGER  newSize 
)
static

Definition at line 294 of file filelockbytes.c.

295 {
297  HRESULT hr = S_OK;
298  LARGE_INTEGER newpos;
299 
300  TRACE("new size %u\n", newSize.u.LowPart);
301 
302  newpos.QuadPart = newSize.QuadPart;
303  if (SetFilePointerEx(This->hfile, newpos, NULL, FILE_BEGIN))
304  {
305  SetEndOfFile(This->hfile);
306  }
307 
308  return hr;
309 }
static FileLockBytesImpl * impl_from_ILockBytes(ILockBytes *iface)
Definition: filelockbytes.c:58
BOOL WINAPI SetFilePointerEx(HANDLE hFile, LARGE_INTEGER liDistanceToMove, PLARGE_INTEGER lpNewFilePointer, DWORD dwMoveMethod)
Definition: fileinfo.c:177
HRESULT hr
Definition: shlfolder.c:183
BOOL WINAPI SetEndOfFile(HANDLE hFile)
Definition: fileinfo.c:1004
#define FILE_BEGIN
Definition: compat.h:620
ULONGLONG QuadPart
Definition: ms-dtyp.idl:185
struct _ULARGE_INTEGER::@3949 u
#define TRACE(s)
Definition: solgame.cpp:4
LONG HRESULT
Definition: typedefs.h:79
#define S_OK
Definition: intsafe.h:51
#define NULL
Definition: types.h:112
LONGLONG QuadPart
Definition: typedefs.h:114

◆ FileLockBytesImpl_Stat()

static HRESULT WINAPI FileLockBytesImpl_Stat ( ILockBytes iface,
STATSTG *  pstatstg,
DWORD  grfStatFlag 
)
static

Definition at line 368 of file filelockbytes.c.

370 {
372 
373  if (!(STATFLAG_NONAME & grfStatFlag) && This->pwcsName)
374  {
375  pstatstg->pwcsName =
376  CoTaskMemAlloc((lstrlenW(This->pwcsName)+1)*sizeof(WCHAR));
377 
378  lstrcpyW(pstatstg->pwcsName, This->pwcsName);
379  }
380  else
381  pstatstg->pwcsName = NULL;
382 
383  pstatstg->type = STGTY_LOCKBYTES;
384 
385  pstatstg->cbSize.u.LowPart = GetFileSize(This->hfile, &pstatstg->cbSize.u.HighPart);
386  /* FIXME: If the implementation is exported, we'll need to set other fields. */
387 
388  pstatstg->grfLocksSupported = LOCK_EXCLUSIVE|LOCK_ONLYONCE|WINE_LOCK_READ;
389 
390  return S_OK;
391 }
static FileLockBytesImpl * impl_from_ILockBytes(ILockBytes *iface)
Definition: filelockbytes.c:58
#define WINE_LOCK_READ
Definition: storage32.h:523
#define lstrlenW
Definition: compat.h:609
__wchar_t WCHAR
Definition: xmlstorage.h:180
DWORD WINAPI GetFileSize(HANDLE hFile, LPDWORD lpFileSizeHigh)
Definition: fileinfo.c:331
#define S_OK
Definition: intsafe.h:51
#define lstrcpyW
Definition: compat.h:608
#define NULL
Definition: types.h:112
LPVOID WINAPI CoTaskMemAlloc(SIZE_T size)
Definition: ifs.c:426

◆ FileLockBytesImpl_UnlockRegion()

static HRESULT WINAPI FileLockBytesImpl_UnlockRegion ( ILockBytes iface,
ULARGE_INTEGER  libOffset,
ULARGE_INTEGER  cb,
DWORD  dwLockType 
)
static

Definition at line 348 of file filelockbytes.c.

350 {
352  OVERLAPPED ol;
353 
354  TRACE("ofs %u count %u flags %x\n", libOffset.u.LowPart, cb.u.LowPart, dwLockType);
355 
356  if (dwLockType & LOCK_WRITE)
357  return STG_E_INVALIDFUNCTION;
358 
359  ol.hEvent = 0;
360  ol.u.s.Offset = libOffset.u.LowPart;
361  ol.u.s.OffsetHigh = libOffset.u.HighPart;
362 
363  if (UnlockFileEx(This->hfile, 0, cb.u.LowPart, cb.u.HighPart, &ol))
364  return S_OK;
365  return get_lock_error();
366 }
static FileLockBytesImpl * impl_from_ILockBytes(ILockBytes *iface)
Definition: filelockbytes.c:58
DWORD Offset
Definition: winbase.h:793
HANDLE hEvent
Definition: winbase.h:798
#define STG_E_INVALIDFUNCTION
Definition: winerror.h:2564
struct _ULARGE_INTEGER::@3949 u
#define TRACE(s)
Definition: solgame.cpp:4
BOOL WINAPI UnlockFileEx(IN HANDLE hFile, IN DWORD dwReserved, IN DWORD nNumberOfBytesToUnLockLow, IN DWORD nNumberOfBytesToUnLockHigh, IN LPOVERLAPPED lpOverlapped)
Definition: lock.c:183
#define S_OK
Definition: intsafe.h:51
DWORD OffsetHigh
Definition: winbase.h:794
static HRESULT get_lock_error(void)
static HMODULE MODULEINFO DWORD cb
Definition: module.c:32

◆ FileLockBytesImpl_WriteAt()

static HRESULT WINAPI FileLockBytesImpl_WriteAt ( ILockBytes iface,
ULARGE_INTEGER  ulOffset,
const void pv,
ULONG  cb,
ULONG pcbWritten 
)
static

Definition at line 233 of file filelockbytes.c.

239 {
241  ULONG bytes_left = cb;
242  const BYTE *writePtr = pv;
243  BOOL ret;
245  ULONG cbWritten;
246 
247  TRACE("(%p)-> %i %p %i %p\n",This, ulOffset.u.LowPart, pv, cb, pcbWritten);
248 
249  /* verify a sane environment */
250  if (!This) return E_FAIL;
251 
252  if (This->flProtect != PAGE_READWRITE)
253  return STG_E_ACCESSDENIED;
254 
255  if (pcbWritten)
256  *pcbWritten = 0;
257 
258  offset.QuadPart = ulOffset.QuadPart;
259 
261 
262  if (!ret)
263  return STG_E_WRITEFAULT;
264 
265  while (bytes_left)
266  {
267  ret = WriteFile(This->hfile, writePtr, bytes_left, &cbWritten, NULL);
268 
269  if (!ret)
270  return STG_E_WRITEFAULT;
271 
272  if (pcbWritten)
273  *pcbWritten += cbWritten;
274 
275  bytes_left -= cbWritten;
276  writePtr += cbWritten;
277  }
278 
279  TRACE("finished\n");
280  return S_OK;
281 }
static FileLockBytesImpl * impl_from_ILockBytes(ILockBytes *iface)
Definition: filelockbytes.c:58
BOOL WINAPI SetFilePointerEx(HANDLE hFile, LARGE_INTEGER liDistanceToMove, PLARGE_INTEGER lpNewFilePointer, DWORD dwMoveMethod)
Definition: fileinfo.c:177
BOOL WINAPI WriteFile(IN HANDLE hFile, IN LPCVOID lpBuffer, IN DWORD nNumberOfBytesToWrite OPTIONAL, OUT LPDWORD lpNumberOfBytesWritten, IN LPOVERLAPPED lpOverlapped OPTIONAL)
Definition: rw.c:24
#define STG_E_WRITEFAULT
Definition: winerror.h:2575
#define FILE_BEGIN
Definition: compat.h:620
#define E_FAIL
Definition: ddrawi.h:102
ULONGLONG QuadPart
Definition: ms-dtyp.idl:185
#define STG_E_ACCESSDENIED
Definition: winerror.h:2568
unsigned int BOOL
Definition: ntddk_ex.h:94
struct _ULARGE_INTEGER::@3949 u
#define TRACE(s)
Definition: solgame.cpp:4
GLintptr offset
Definition: glext.h:5920
int ret
unsigned char BYTE
Definition: xxhash.c:193
#define S_OK
Definition: intsafe.h:51
#define NULL
Definition: types.h:112
static HMODULE MODULEINFO DWORD cb
Definition: module.c:32
unsigned int ULONG
Definition: retypes.h:1
#define PAGE_READWRITE
Definition: nt_native.h:1304

◆ get_lock_error()

static HRESULT get_lock_error ( void  )
static

Definition at line 311 of file filelockbytes.c.

312 {
313  switch (GetLastError())
314  {
315  case ERROR_LOCK_VIOLATION: return STG_E_LOCKVIOLATION; break;
316  case ERROR_ACCESS_DENIED: return STG_E_ACCESSDENIED; break;
317  case ERROR_NOT_SUPPORTED: return STG_E_INVALIDFUNCTION; break;
318  default:
319  FIXME("no mapping for error %d\n", GetLastError());
320  return STG_E_INVALIDFUNCTION;
321  }
322 }
DWORD WINAPI GetLastError(VOID)
Definition: except.c:1044
#define ERROR_ACCESS_DENIED
Definition: compat.h:97
#define STG_E_ACCESSDENIED
Definition: winerror.h:2568
#define FIXME(fmt,...)
Definition: debug.h:111
#define STG_E_INVALIDFUNCTION
Definition: winerror.h:2564
#define STG_E_LOCKVIOLATION
Definition: winerror.h:2578
#define ERROR_NOT_SUPPORTED
Definition: compat.h:100
#define ERROR_LOCK_VIOLATION
Definition: winerror.h:136

Referenced by FileLockBytesImpl_LockRegion(), and FileLockBytesImpl_UnlockRegion().

◆ GetProtectMode()

static DWORD GetProtectMode ( DWORD  openFlags)
static

Definition at line 73 of file filelockbytes.c.

74 {
75  switch(STGM_ACCESS_MODE(openFlags))
76  {
77  case STGM_WRITE:
78  case STGM_READWRITE:
79  return PAGE_READWRITE;
80  }
81  return PAGE_READONLY;
82 }
#define STGM_WRITE
Definition: objbase.h:917
#define STGM_READWRITE
Definition: objbase.h:918
#define STGM_ACCESS_MODE(stgm)
Definition: storage32.h:115
#define PAGE_READONLY
Definition: compat.h:138
#define PAGE_READWRITE
Definition: nt_native.h:1304

Referenced by FileLockBytesImpl_Construct().

◆ impl_from_ILockBytes()

static FileLockBytesImpl* impl_from_ILockBytes ( ILockBytes iface)
inlinestatic

Definition at line 58 of file filelockbytes.c.

59 {
60  return CONTAINING_RECORD(iface, FileLockBytesImpl, ILockBytes_iface);
61 }
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 FileLockBytesImpl_AddRef(), FileLockBytesImpl_LockRegion(), FileLockBytesImpl_ReadAt(), FileLockBytesImpl_Release(), FileLockBytesImpl_SetSize(), FileLockBytesImpl_Stat(), FileLockBytesImpl_UnlockRegion(), and FileLockBytesImpl_WriteAt().

◆ WINE_DEFAULT_DEBUG_CHANNEL()

WINE_DEFAULT_DEBUG_CHANNEL ( storage  )

Variable Documentation

◆ FileLockBytesImpl_Vtbl

static const ILockBytesVtbl FileLockBytesImpl_Vtbl
static
Initial value:
= {
}
static HRESULT WINAPI FileLockBytesImpl_Stat(ILockBytes *iface, STATSTG *pstatstg, DWORD grfStatFlag)
static HRESULT WINAPI FileLockBytesImpl_WriteAt(ILockBytes *iface, ULARGE_INTEGER ulOffset, const void *pv, ULONG cb, ULONG *pcbWritten)
static HRESULT WINAPI FileLockBytesImpl_Flush(ILockBytes *iface)
static HRESULT WINAPI FileLockBytesImpl_ReadAt(ILockBytes *iface, ULARGE_INTEGER ulOffset, void *pv, ULONG cb, ULONG *pcbRead)
static HRESULT WINAPI FileLockBytesImpl_SetSize(ILockBytes *iface, ULARGE_INTEGER newSize)
static ULONG WINAPI FileLockBytesImpl_AddRef(ILockBytes *iface)
static ULONG WINAPI FileLockBytesImpl_Release(ILockBytes *iface)
static HRESULT WINAPI FileLockBytesImpl_LockRegion(ILockBytes *iface, ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType)
static HRESULT WINAPI FileLockBytesImpl_QueryInterface(ILockBytes *iface, REFIID riid, void **ppvObject)
static HRESULT WINAPI FileLockBytesImpl_UnlockRegion(ILockBytes *iface, ULARGE_INTEGER libOffset, ULARGE_INTEGER cb, DWORD dwLockType)

Definition at line 56 of file filelockbytes.c.

Referenced by FileLockBytesImpl_Construct().