Share via


RasGetBuffer (Windows Embedded CE 6.0)

1/6/2010

This function allocates memory for sending or receiving data over the port connected to the server. A custom-scripting DLL, which is implemented by the developer, calls RasGetBuffer through a function pointer. RAS passes the function pointer through the phnRasGetBuffer parameter of the DLL's RasCustomScriptExecute function.

Syntax

typedef DWORD (APIENTRY *PFNRASGETBUFFER)(
  PBYTE* ppBuffer, 
  PDWORD pdwSize 
);

Parameters

  • ppBuffer
    Pointer to a pointer that receives the address of the returned buffer.
  • pdwSize
    Pointer to a DWORD variable that, on input, contains the requested size of the buffer. On output, this variable contains the actual size of the buffer allocated.

Return Value

  • ERROR_SUCCESS
    The function was successful.
  • ERROR_BUFFER_INVALID
    The pointer to the buffer passed in the ppBuffer parameter is invalid.

Remarks

The maximum buffer size that can be allocated is 1500 bytes.

The custom-scripting DLL calls RasGetBuffer through a function pointer.

Requirements

Header ras.h
Library Ppp.lib
Windows Embedded CE Windows CE .NET 4.0 and later

See Also

Reference

Scripting Functions
RasCustomScriptExecute
RasFreeBuffer

Concepts

RAS Custom Scripting