Please note, this is a STATIC archive of website developer.mozilla.org from 03 Nov 2016, cach3.com does not collect or store any user information, there is no "phishing" involved.

NPN_ReleaseVariantValue

« Gecko Plugin API Reference « Scripting plugins

Summary

NPN_ReleaseVariantValue() releases the value in the given variant.

Syntax

#include <npruntime.h>
 
void NPN_ReleaseVariantValue(NPVariant *variant);

Parameters

The function has the following parameters:

<tt>variant</tt>
The variant whose value is to be released.

Returns

Nothing.

Description

NPN_ReleaseVariantValue() releases the value in the given variant. This must always be called on result variants and such in this API, i.e. any NPVariant whose value comes from a call that passes back an NPVariant must be released using this function. Access to the value in an NPVariant that has been released will result in undefined behavior.

NPN_ReleaseVariantValue() will call NPN_ReleaseObject() on NPVariants of type NPVARIANTTYPE_OBJECT, and NPN_MemFree() on NPVariants of type NPVARIANTTYPE_STRING.

Document Tags and Contributors

Tags: 
 Contributors to this page: teoli, Mcs, Sheppy
 Last updated by: Mcs,