HttpFindNameAndValue

Finds the specified name and returns its value.

Syntax

    #include <httpexp.h>
    
    int HttpFindNameAndValue (
      char  *pBuffer,
      char  *pzTokenName,
      char  *pzTokenValue,
      int   *pzTokenValueMaxLen);
    

Parameters

pBuffer
(IN) Points to a NULL terminated buffer to search for the specified name
pzTokenName
(IN) Points to the NULL terminated name to find in the specified buffer. The check is case sensitive.
pzTokenValue
(OUT) Points to the buffer that receives the token value.
pzTokenValueMaxLen
(IN/OUT) Points to an int that contains the maximum length of the pzTokenValue buffer. On return, the length specifies the length of the value found or the length of the buffer needed if the original pzTokenValue buffer is too small.

Return Values

If successful, returns 0. Otherwise, returns a nonzero error code.

Decimal

Name

Description

119

ERR_BUFFER_TOO_SMALL

The pzTokenValue buffer is too small.

121

ERR_NO_ITEMS_FOUND

Name does not exist in buffer.

255

ERR_BAD_PARAMETER

Invalid input parameters.