Exemplo n.º 1
0
//--------------------------------------------------------------------
void
GSWHTTPRequest_Free(GSWHTTPRequest *p_pHTTPRequest,
                    void           *p_pLogServerData)
{
    GSWDebugLog(p_pLogServerData,"Start GSWHTTPRequest_Free");
    if (p_pHTTPRequest)
    {
        if (p_pHTTPRequest->pHeaders)
        {
            GSWDict_Free(p_pHTTPRequest->pHeaders);
            p_pHTTPRequest->pHeaders=NULL;
        };
        if (p_pHTTPRequest->pszRequest)
        {
            free(p_pHTTPRequest->pszRequest);
            p_pHTTPRequest->pszRequest=NULL;
        };
        if (p_pHTTPRequest->pContent)
        {
            free(p_pHTTPRequest->pContent);
            p_pHTTPRequest->pContent=NULL;
        };
        free(p_pHTTPRequest);
        p_pHTTPRequest=NULL;
    };
    GSWDebugLog(p_pLogServerData,"Stop GSWHTTPRequest_Free");
};
Exemplo n.º 2
0
//--------------------------------------------------------------------
void
GSWUtil_ClearHostCache()
{
  if (g_pHostCache)
    {
      GSWDict_Free(g_pHostCache);
      g_pHostCache=NULL;
    };
};