#include <stdarg.h>
#include "windef.h"
#include "winbase.h"
#include "rpc.h"
#include "rpcndr.h"
#include "wine/debug.h"
Go to the source code of this file.
|
| WINE_DEFAULT_DEBUG_CHANNEL (rpc) |
|
PFULL_PTR_XLAT_TABLES WINAPI | NdrFullPointerXlatInit (ULONG NumberOfPointers, XLAT_SIDE XlatSide) |
|
void WINAPI | NdrFullPointerXlatFree (PFULL_PTR_XLAT_TABLES pXlatTables) |
|
static void | expand_pointer_table_if_necessary (PFULL_PTR_XLAT_TABLES pXlatTables, ULONG RefId) |
|
int WINAPI | NdrFullPointerQueryPointer (PFULL_PTR_XLAT_TABLES pXlatTables, void *pPointer, unsigned char QueryType, ULONG *pRefId) |
|
int WINAPI | NdrFullPointerQueryRefId (PFULL_PTR_XLAT_TABLES pXlatTables, ULONG RefId, unsigned char QueryType, void **ppPointer) |
|
void WINAPI | NdrFullPointerInsertRefId (PFULL_PTR_XLAT_TABLES pXlatTables, ULONG RefId, void *pPointer) |
|
int WINAPI | NdrFullPointerFree (PFULL_PTR_XLAT_TABLES pXlatTables, void *Pointer) |
|
◆ expand_pointer_table_if_necessary()
◆ NdrFullPointerFree()
Definition at line 214 of file ndr_fullpointer.c.
215{
220
221 TRACE(
"(%p, %p)\n", pXlatTables, Pointer);
222
223 if (!Pointer)
224 return 1;
225
226
227 for (
i = 0;
i <
sizeof(Pointer);
i++)
228 Hash = (
Hash * 3) ^ ((
unsigned char *)&Pointer)[
i];
229
231 for (; XlatTableEntry; XlatTableEntry = XlatTableEntry->
Next)
232 if (Pointer == XlatTableEntry->
Pointer)
233 {
234 if (XlatTableEntry->
State & 0x20)
235 return 0;
236 XlatTableEntry->
State |= 0x20;
237 RefId = XlatTableEntry->
RefId;
238 break;
239 }
240
241 if (!XlatTableEntry)
242 return 0;
243
245 {
247 return 1;
248 }
249
250 return 0;
251}
static int Hash(const char *)
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
struct _FULL_PTR_TO_REFID_ELEMENT * Next
struct _FULL_PTR_XLAT_TABLES::@3234 PointerToRefId
Referenced by PointerFree(), and test_fullpointer_xlat().
◆ NdrFullPointerInsertRefId()
Definition at line 188 of file ndr_fullpointer.c.
190{
194
195 TRACE(
"(%p, 0x%x, %p)\n", pXlatTables, RefId, pPointer);
196
197
198 for (
i = 0;
i <
sizeof(pPointer);
i++)
199 Hash = (
Hash * 3) ^ ((
unsigned char *)&pPointer)[
i];
200
203 XlatTableEntry->
Pointer = pPointer;
204 XlatTableEntry->
RefId = RefId;
205 XlatTableEntry->
State = 0;
207
208
212}
static void expand_pointer_table_if_necessary(PFULL_PTR_XLAT_TABLES pXlatTables, ULONG RefId)
Referenced by PointerUnmarshall(), and test_fullpointer_xlat().
◆ NdrFullPointerQueryPointer()
Definition at line 109 of file ndr_fullpointer.c.
112{
116
117 TRACE(
"(%p, %p, %d, %p)\n", pXlatTables, pPointer,
QueryType, pRefId);
118
119 if (!pPointer)
120 {
121 *pRefId = 0;
122 return 1;
123 }
124
125
126 for (
i = 0;
i <
sizeof(pPointer);
i++)
127 Hash = (
Hash * 3) ^ ((
unsigned char *)&pPointer)[
i];
128
130 for (; XlatTableEntry; XlatTableEntry = XlatTableEntry->
Next)
131 if (pPointer == XlatTableEntry->
Pointer)
132 {
133 *pRefId = XlatTableEntry->
RefId;
135 return 1;
137 return 0;
138 }
139
142 XlatTableEntry->
Pointer = pPointer;
146
147
150 {
153 }
154
155 return 0;
156}
_Must_inspect_result_ _In_ KTMOBJECT_TYPE QueryType
Referenced by PointerBufferSize(), PointerMarshall(), and test_fullpointer_xlat().
◆ NdrFullPointerQueryRefId()
◆ NdrFullPointerXlatFree()
Definition at line 64 of file ndr_fullpointer.c.
65{
67
68 TRACE(
"(%p)\n", pXlatTables);
69
70
72 {
75 XlatTableEntry; )
76 {
79 XlatTableEntry =
Next;
80 }
81 }
82
86
88}
#define HeapFree(x, y, z)
STDMETHOD() Next(THIS_ ULONG celt, IAssociationElement *pElement, ULONG *pceltFetched) PURE
Referenced by ndr_client_call_finally(), NdrMesProcEncodeDecode(), NdrpCompleteAsyncClientCall(), NdrpCompleteAsyncServerCall(), NdrStubCall2(), and test_fullpointer_xlat().
◆ NdrFullPointerXlatInit()
◆ WINE_DEFAULT_DEBUG_CHANNEL()
WINE_DEFAULT_DEBUG_CHANNEL |
( |
rpc |
| ) |
|