qr2_parse_query

GameSpy SDK

qr2_parse_query

When using the shared socket method with qr2_init_socket, use this function to pass qr2 messages to the qr2 sdk.

void qr2_parse_query(
qr2_t qrec,
gsi_char * query,
int len,
struct sockaddr * sender );
RoutineRequired HeaderDistribution
qr2_parse_query<qr2.h>SDKZIP

Parameters

qrec
[in] Initialize QR2 SDK initialized with qr2_init_socket.
query
[in] The QR2 packet received on the socket. See remarks.
len
[in] The length of the QR2 packet.
sender
[in] The sender of the packet.

Remarks

The qr2_parse_query function should be used in the shared socket implementation on qr2.  In this implementation, the developer is responsible for creating and receiving on the socket, and forwarding qr2 messages to the sdk. The qr2 messages may be identified by the packet header.  QR1 packets begin with a single backslash ‘\’ character,  QR2 packets begin with the QR_MAGIC_1 character followed by the QR_MAGIC_2 character.

Unicode Mappings

RoutineGSI_UNICODE Not DefinedGSI_UNICODE Defined
qr2_parse_queryqr2_parse_queryAqr2_parse_queryW

qr2_parse_queryW and qr2_parse_queryA are UNICODE and ANSI mapped versions of qr2_parse_query. The arguments of qr2_parse_queryA are ANSI strings; those of qr2_parse_queryW are wide-character strings.