These types come from the demos for FastCGI Dll Library (with SIGTERM handler) for Windows Web Servers and are written in PowerBASIC. I'm trying to convert them to VB6 (having also discovered how to call a CDECL DLL from VB6).
' Structures
TYPE FCGX_STREAM
pData AS DWORD ' Pointer to the first byte of data
LenStored AS DWORD ' Bytes Total data stored - up to 4.2GB
Capacity AS DWORD ' Bytes Total available - up to 4.2GB
CurPos AS DWORD ' Current Position within the buffer of the next byte to read, as an offset from pData
Reserved AS STRING*12 ' Opaque Variables
END TYPE ' 28 bytes
TYPE FCGX_REQUEST
Version AS LONG ' Dll Version Number * 1000 = %FCGI_VERSION
ReqCount AS LONG ' Request Counter
Role AS LONG ' FastCGI Role
ConnFlags AS LONG ' Connection flags - zero = application closes connection after responding
ReqMethod AS LONG ' Request HTTP Method - Code 1 - 8
ContLen AS LONG ' CONTENT_LENGTH - Length of POST data sent (in the pInStream Data String)
pzQuery AS ASCIIZ PTR ' Pointer to ASCIIZ (Null Terminated) QUERY_STRING (Values Only) - Always a valid pointer
nParam AS LONG ' Number of Request Params in the array
envp AS DWORD PTR ' Pointer to Array of Request Parameters
pIn AS FCGX_STREAM PTR ' Pointer to a String Builder object
pOut AS FCGX_STREAM PTR ' Pointer to a String Builder object
pErr AS FCGX_STREAM PTR ' Pointer to a String Builder object
pzLastErr AS ASCIIZ PTR ' Pointer to ASCIIZ String containing Last Error description
Reserved AS STRING*108 ' Opaque Variables
END TYPE ' 160 bytes
My problem is in comprehending how to get at the information stored in ASCIIZ PTR
, FCGX_STREAM PTR
and DWORD PTR
items.