Skip to main content
Version: 16.10.0

GW2GetIdInfo

Every issue identified and reported by the Glasswall engine has a unique issue ID associated. This API provides a description for a given Issue ID number.

Synopsis

For session session , GW2GetIdInfo places in the object pointed to by outputBuffer , a pointer to a description of Glasswall Issue ID issueId. The length of the description, in bytes, is placed in the size_t object pointed to by bufferLength.


#include "glasswall.core2.api.h"

int GW2GetIdInfo(
Session session,
size_t issueId,
size_t *bufferLength,
char **outputBuffer);

Returns

Returns an integer GW2_RetStatus enum value. Negative numbers indicate a failure. If successful, the output buffer is populated with the Issue Description.

Example


#include "glasswall.core2.api.h"

char *outbuf = NULL;
size_t buflen = 0;

if (GW2OpenSession() < 0)
/* error opening session */
else
{
int status = GW2GetIdInfo(session, issueId, &buflen, &outbuf);

/* outbuf points to a buffer containing the XML file.
* Either process the data pointed to, or copy the data and process it
* after GW2CloseSession is called
*/

if (GW2CloseSession() < 0)
/* error closing session */
}