> ## Documentation Index
> Fetch the complete documentation index at: https://devdocs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# XtfClosePackageInfo

> XtfClosePackageInfo

# XtfClosePackageInfo

Frees a package information object.

<a id="syntaxSection" />

## Syntax

```cpp theme={null}
void XtfClosePackageInfo(
         XtfPackageInfo packageInfo
)  
```

<a id="parametersSection" />

### Parameters

*packageInfo*\
Type: XtfPackageInfo

\[in] A pointer to the information object for a package.

<a id="retvalSection" />

### Return value

None.

<a id="remarksSection" />

## Remarks

Use this function to release the pointer to the information object for a registered package, returned by either the [XtfRegisterPackage](/reference/tools/xtf/xtfapi/functions/xtfregisterpackage-xtfapi-xbox-windows-m) or [XtfRegisterNetworkSharePackage](/reference/tools/xtf/xtfapi/functions/xtfregisternetworksharepackage-xtfapi-xbox-windows-m) function. The information object is used by the [XtfGetAumid](/reference/tools/xtf/xtfapi/functions/xtfgetaumid-xtfapi-xbox-windows-m), [XtfGetcountofAppUserModelIds](/reference/tools/xtf/xtfapi/functions/xtfgetcountofappusermodelids-xtfapi-xbox-windows-m), and the [XtfGetPackageFullName](/reference/tools/xtf/xtfapi/functions/xtfgetpackagefullname-xtfapi-xbox-windows-m) functions to retrieve information for a package. For more information about packages, see [Packaging](/build/core-features/common/packaging/gc-packaging-toc).

<Note>You must call this function to release the pointer to an information object for a package. Otherwise, the information object is orphaned and the resources associated with it aren't freed, causing a memory leak.</Note>

<a id="requirements" />

## Requirements

**Header:** xtfapi.h

**Library:** XtfApi.lib

**Supported platforms:** Windows (for XBOX console tools)

<a id="seealsoSection" />

## See also

[XTF Transport Errors (NDA topic)](/tools/tools-console/commandlinetools/xtf-transport-errors)\
[Additional Xtf APIs](/reference/tools/xtf/xtfapi/atoc-xtfapi)


## Related topics

- [XtfRegisterNetworkSharePackage](/reference/tools/xtf/xtfapi/functions/xtfregisternetworksharepackage-xtfapi-xbox-windows-m.md)
- [XtfRegisterPackage](/reference/tools/xtf/xtfapi/functions/xtfregisterpackage-xtfapi-xbox-windows-m.md)
- [XtfRegisterPackageOnDrive](/reference/tools/xtf/xtfapi/functions/xtfregisterpackageondrive-xtfapi-xbox-windows-m.md)
- [XtfCloseConsoleInfoList](/reference/tools/xtf/xtfapi/functions/xtfcloseconsoleinfolist-xbox-microsoft-m.md)
- [XtfCloseCredentialInfoList](/reference/tools/xtf/xtfapi/functions/xtfclosecredentialinfo-xtfapi-xbox-windows-m.md)
