srv_langcpy

Copies part of the language request buffer.

Syntax

long srv_langcpy (
SRV_PROC *
srvproc,
long
start,
long
nbytes,
DBCHAR *
buffer );

where

srvproc
Is a pointer to the SRV_PROC structure that is the handle for a particular client connection (in this case, the handle that received the language request). The structure contains the information that the ODS Library uses to manage communication and data between an Open Data Services server application and the client.
start
Indicates where to start copying characters from the request buffer. Command buffer characters are numbered beginning with 0.
nbytes
Specifies the number of bytes to copy. If nbytes is -1, srv_langcpy copies the number of bytes available in the request buffer. If there are less than nbytes bytes available to copy, srv_langcpy copies all the bytes in the request buffer.
buffer
Provides a DBCHAR pointer to the developer-supplied buffer in which to copy the bytes.

Returns

The number of bytes copied. If there is no current language request from the client, returns -1.

Remarks

The srv_langcpy function null-terminates the part of the language request buffer copied into buffer. This function assumes that buffer is large enough to handle (bytes 1) bytes. The request buffer can contain an ASCII string.

See Also

This entry For information about
srv_langptr Returning a pointer to the language request buffer
srv_langlen Returning the length of the language request buffer