---
name: "cgiFree"
section: "3"
platform: "linux"
package: "cgilib"
version: "0.6-1.1+b1"
release: "Debian 11 (Bullseye)"
platforms: ["linux"]
url: "https://new.carta.tech/cgiFree"
---

# cgiFree(3)

Frees CGI data structure

## NAME

cgiFree - Frees CGI data structure

## SYNOPSYS

```
#include <cgi.h>

void cgiFree (s_cgi *parms);
```

## DESCRIPTION

This routine frees memory allocated by CGI parsing routines. Temporary files from CGI file upload are also removed. This is the opposite of [**cgiInit**(3)](/cgiInit/3.md).

After this routine was called, no variables, cookies, files and no additional header lines are available.  The result type is also reset to "text/html".

## AUTHOR

This CGI library is written by Martin Schulze \<joey@infodrom.org\>.  If you have additions or improvements please get in touch with him.

## SEE ALSO

[**cgiInit**(3)](/cgiInit/3.md), [**cgiDebug**(3)](/cgiDebug/3.md), [**cgiHeader**(3)](/cgiHeader/3.md), [**cgiSetHeader**(3)](/cgiSetHeader/3.md), [**cgiSetType**(3)](/cgiSetType/3.md), [**cgiGetValue**(3)](/cgiGetValue/3.md), [**cgiGetVariables**(3)](/cgiGetVariables/3.md) [**cgiGetCookie**(3)](/cgiGetCookie/3.md), [**cgiGetCookies**(3)](/cgiGetCookies/3.md).
